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

fix parse interpolation error #159

Merged

Conversation

heychenfq
Copy link

@heychenfq heychenfq commented May 12, 2021

hello, when i use postcss-less as less preprocessor parser in my project, i get some parse error.
here is my example:
@{prefix}-title{\ncolor: red;};

i try debug internal code, i found that when parse interpolation, token match would not stop util not match @|{|}, in my example, the final match token is @{prefix}-title{,i guess this works unexpected,so i try to fix it. make the { token just match once, in my project, it works fine.

Please check one:

  • New tests created for this change

This PR:

  • Adds new API
  • Extends existing API, backwards-compatible
  • Introduces a breaking change
  • Fixes a bug

@heychenfq heychenfq force-pushed the fix-parse-interpolation-error branch from ec6d7ad to b5e6633 Compare May 12, 2021 04:46
@heychenfq heychenfq force-pushed the fix-parse-interpolation-error branch from b5e6633 to 5e1fa13 Compare May 12, 2021 04:49
@shellscape
Copy link
Owner

thanks!

@shellscape shellscape merged commit 3fba092 into shellscape:master Jul 12, 2021
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 6, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 6, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 6, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 6, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 6, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 7, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
yassin-kammoun-sonarsource added a commit to SonarSource/SonarJS that referenced this pull request Apr 7, 2022
The bug mentioned in the test was fixed with shellscape/postcss-less#159
malei0311 added a commit to malei0311/prettier that referenced this pull request Feb 10, 2023
malei0311 added a commit to malei0311/prettier that referenced this pull request Feb 10, 2023
malei0311 added a commit to malei0311/prettier that referenced this pull request Feb 10, 2023
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

Successfully merging this pull request may close these issues.

2 participants