> [!WARNING]<br>
> **Known issues:**
> - This tool won't work with [user-defined value types](https://docs.soliditylang.org/en/latest/types.html#user-defined-value-types). For events that include these types, you must manually convert the user-defined value type into its equivalent primitive type.
-> - This tool won't work with multi-line event definitions. For events that span multiple lines, you must manually collapse the definition into one line.
## Example
strict = true;
continue;
}
+ // Basic lookahead for event definitions that span multiple lines
+ if ((line.match(/\(/g)?.length ?? 0) > (line.match(/\)/g)?.length ?? 0)) {
+ const start = code.indexOf(line);
+ const end = code.indexOf(')', start);
+ const lookaheadLine = code.substring(start, end + 1).replaceAll('\n', '');
+ try {
+ const normalizedEvent = normalizeEvent(lookaheadLine, strict);
+ events.add(normalizedEvent);
+ }
+ catch { }
+ continue;
+ }
try {
const normalizedEvent = normalizeEvent(line, strict);
events.add(normalizedEvent);