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

Preprocessor directive recognised when not entirely preceded by horizontal whitespace #1

Closed
atifaziz opened this issue Mar 27, 2019 · 2 comments
Labels
good first issue Good for newcomers

Comments

@atifaziz
Copy link
Owner

Using version 1.0.1:

$ echo "foo #bar baz" | csmin tokens -f line
Text 0/1:1...3/1:4 "foo"
WhiteSpace 3/1:4...4/1:5 " "
PreprocessorDirective 4/1:5...12/1:13 "#bar baz"
NewLine 12/1:13...13/2:1 "\n"
@atifaziz atifaziz added bug Something isn't working and removed bug Something isn't working labels Mar 27, 2019
@atifaziz
Copy link
Owner Author

This is not a bug because minifier results are undefined if input C# source is invalid in the first place. Still, it would be good to not recognise regions that are not preceded by horizontal whitespace entirely.

@atifaziz atifaziz added the good first issue Good for newcomers label Mar 27, 2019
@atifaziz atifaziz changed the title Preprocessor directive recognised after any whitespace Don't recognise preprocessor directives when not entirely preceded by horizontal whitespace Mar 27, 2019
@atifaziz atifaziz changed the title Don't recognise preprocessor directives when not entirely preceded by horizontal whitespace Preprocessor directive recognised when not entirely preceded by horizontal whitespace Mar 27, 2019
@atifaziz
Copy link
Owner Author

Closed by 1e8a189.

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

No branches or pull requests

1 participant