Skip to content

Commit

Permalink
Erlang: Added begin keyword (#3387)
Browse files Browse the repository at this point in the history
  • Loading branch information
hoonweiting committed Mar 13, 2022
1 parent 31a38d0 commit cf38d05
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion components/prism-erlang.js
Expand Up @@ -13,7 +13,7 @@ Prism.languages.erlang = {
alias: 'atom'
},
'boolean': /\b(?:false|true)\b/,
'keyword': /\b(?:after|case|catch|end|fun|if|of|receive|try|when)\b/,
'keyword': /\b(?:after|begin|case|catch|end|fun|if|of|receive|try|when)\b/,
'number': [
/\$\\?./,
/\b\d+#[a-z0-9]+/i,
Expand Down
2 changes: 1 addition & 1 deletion components/prism-erlang.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions tests/languages/erlang/keyword_feature.test
@@ -1,15 +1,15 @@
fun when case of
end if receive
begin end if receive
after try catch

----------------------------------------------------

[
["keyword", "fun"], ["keyword", "when"], ["keyword", "case"], ["keyword", "of"],
["keyword", "end"], ["keyword", "if"], ["keyword", "receive"],
["keyword", "begin"], ["keyword", "end"], ["keyword", "if"], ["keyword", "receive"],
["keyword", "after"], ["keyword", "try"], ["keyword", "catch"]
]

----------------------------------------------------

Checks for all keywords.
Checks for all keywords.

0 comments on commit cf38d05

Please sign in to comment.