Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

syntax highlighting triggers on apostrophe #69

Open
nmz787 opened this issue Feb 1, 2019 · 2 comments
Open

syntax highlighting triggers on apostrophe #69

nmz787 opened this issue Feb 1, 2019 · 2 comments

Comments

@nmz787
Copy link

nmz787 commented Feb 1, 2019

if I have a lines like this:

:don't break the code!|
:you're coding all night|

the text between the apostrophe's is assumed to be a quote. In this example the highlighting stops on the second line, but in my specific case I only had one apostrophe and no more after for 10 lines or more... so the entire remainder of the document is highlighted yellow as a result.

@nmz787
Copy link
Author

nmz787 commented Feb 1, 2019

I think this might fix it:

- match: (?:^[^:])\'
      scope: string.quoted.single.source.wsd
      push:
        - meta_scope: string.quoted.single.source.wsd
        - match: \'
          pop: true

@nmz787
Copy link
Author

nmz787 commented Feb 1, 2019

but really I guess the regex should be asserting that a quoted line ends with a quote OR fails if it finds a line-ending character like ; or |

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant