Skip to content

Commit 16fd666

Browse files
authored
Fix a bug that ate functions ;) (#702)
1 parent ee9558d commit 16fd666

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lexers/embedded/c.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,9 @@
218218
<token type="Punctuation"/>
219219
</bygroups>
220220
</rule>
221+
<rule pattern="\b[A-Za-z_]\w*(?=\s*\()">
222+
<token type="NameFunction"/>
223+
</rule>
221224
<rule pattern="[a-zA-Z_]\w*">
222225
<token type="Name"/>
223226
</rule>
@@ -226,7 +229,7 @@
226229
<rule>
227230
<include state="whitespace"/>
228231
</rule>
229-
<rule pattern="((?:[\w*\s])+?(?:\s|[*]))([a-zA-Z_]\w*)(\s*\([^;]*?\))([^;{]*)(\{)|\b[a-z_]\w*(?=\s*\()">
232+
<rule pattern="((?:[\w*\s])+?(?:\s|[*]))([a-zA-Z_]\w*)(\s*\([^;]*?\))([^;{]*)(\{)">
230233
<bygroups>
231234
<usingself state="root"/>
232235
<token type="NameFunction"/>

0 commit comments

Comments
 (0)