Skip to content

Commit d896622

Browse files
committed
Smalltalk: Simplified patterns
1 parent 6f42a79 commit d896622

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

components/prism-smalltalk.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Prism.languages.smalltalk = {
33
'string': /'(?:''|[^'])+'/,
44
'symbol': /#[\da-z]+|#(?:-|([+\/\\*~<>=@%|&?!])\1?)|#(?=\()/i,
55
'block-arguments': {
6-
pattern: /(\[\s*)(?=:)[^\[|]+?\|/,
6+
pattern: /(\[\s*):[^\[|]*?\|/,
77
lookbehind: true,
88
inside: {
99
'variable': /:[\da-z]+/i,
@@ -26,6 +26,6 @@ Prism.languages.smalltalk = {
2626
/\d+r-?[\dA-Z]+(?:\.[\dA-Z]+)?(?:e-?\d+)?/,
2727
/(?:\B-|\b)\d+(?:\.\d+)?(?:e-?\d+)?/
2828
],
29-
'operator': /[:=~<>]=|~~|\/\/|\\\\|>>|[!^=<>+\-*\/&|,@]/,
29+
'operator': /[<=]=?|:=|~[~=]|\/\/?|\\\\|>[>=]?|[!^+\-*&|,@]/,
3030
'punctuation': /[.;:?\[\](){}]/
3131
};

components/prism-smalltalk.min.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)