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

strange issue with protected # symbol. #330

Open
taylorh140 opened this issue Dec 18, 2024 · 2 comments
Open

strange issue with protected # symbol. #330

taylorh140 opened this issue Dec 18, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@taylorh140
Copy link

I got a downstream issue:

classDiagram
  class Shape {
    #area: double
}

where this doesn't work without adding a space after "#"

taylorh140/typst-pintora#5

It seems to be present in the current live version at this time as well.
They found that they can work around it by putting a zero width character in the input, but that's not really optimal.

@hikerpig hikerpig self-assigned this Dec 19, 2024
@hikerpig hikerpig added the bug Something isn't working label Dec 19, 2024
@hikerpig
Copy link
Owner

I see , this is a parser bug, I'll fix as soon as possible

Error: Syntax error at line 4 col 5:

      #area
      ^
Unexpected COLOR token: "#area". Instead, I was expecting to see one of the following:

@hikerpig
Copy link
Owner

I've fixed this and published @pintora/[email protected] , you may update it.
This minor change version also contains some new features about @pre block. I am also working on some upcoming ideas about style system, so it will be some time before the 0.8.0 version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants