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

tests/default_typeclass.x: remove spaces around as-pattern #185

Merged
merged 1 commit into from
Apr 24, 2021
Merged

tests/default_typeclass.x: remove spaces around as-pattern #185

merged 1 commit into from
Apr 24, 2021

Conversation

vaibhavsagar
Copy link
Contributor

I'm getting the following error when trying to run the tests with GHC 9.0.1:

ghc -Wall -fwarn-incomplete-uni-patterns -fno-warn-missing-signatures -fno-warn-unused-imports -fno-warn-tabs -Werror -package array -package bytestring  default_typeclass.n.hs -o default_typeclass.n.bin
[1 of 1] Compiling Main             ( default_typeclass.n.hs, default_typeclass.n.o )

default_typeclass.x:136:7: error:
    Found a binding for the ‘@’ operator in a pattern position.
    Perhaps you meant an as-pattern, which must not be surrounded by whitespace
    Possibly caused by a missing 'do'?
    |
136 |     s @ AlexState { alex_errs = errs } <- get
    |       ^
make: *** [Makefile:72: default_typeclass.n.bin] Error 1
/build/alex-3.2.6/dist/build/alex/alex  -g default_typeclass.x -o default_typeclass.g.hs
ghc -Wall -fwarn-incomplete-uni-patterns -fno-warn-missing-signatures -fno-warn-unused-imports -fno-warn-tabs -Werror -package array -package bytestring  default_typeclass.g.hs -o default_typeclass.g.bin
[1 of 1] Compiling Main             ( default_typeclass.g.hs, default_typeclass.g.o )

default_typeclass.x:136:7: error:
    Found a binding for the ‘@’ operator in a pattern position.
    Perhaps you meant an as-pattern, which must not be surrounded by whitespace
    Possibly caused by a missing 'do'?
    |
136 |     s @ AlexState { alex_errs = errs } <- get
    |       ^

@vaibhavsagar
Copy link
Contributor Author

Confirmed that the tests run successfully with this patch applied on GHC 9.0.1.

@Ericson2314
Copy link
Collaborator

Thanks! :)

@Ericson2314 Ericson2314 merged commit c020dde into haskell:master Apr 24, 2021
@vaibhavsagar
Copy link
Contributor Author

My pleasure!

@vaibhavsagar vaibhavsagar deleted the fix-as-pattern branch April 24, 2021 16:00
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.

None yet

2 participants