Skip to content

Commit

Permalink
Python: Made comment greedy (#3249)
Browse files Browse the repository at this point in the history
  • Loading branch information
RunDevelopment committed Dec 2, 2021
1 parent 18c9204 commit 8ecef30
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion components/prism-python.js
@@ -1,7 +1,8 @@
Prism.languages.python = {
'comment': {
pattern: /(^|[^\\])#.*/,
lookbehind: true
lookbehind: true,
greedy: true
},
'string-interpolation': {
pattern: /(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,
Expand Down
2 changes: 1 addition & 1 deletion components/prism-python.min.js

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

0 comments on commit 8ecef30

Please sign in to comment.