Closed Mikolaj closed 2 years ago
I have the same problem with NoImplicitPrelude
. Here is my .stylish-haskell.yaml
:
steps:
- simple_align:
cases: true
top_level_patterns: true
records: true
# Import cleanup
- imports:
align: none
list_align: after_alias
pad_module_names: false
long_list_align: inline
empty_list_align: inherit
list_padding: 4
separate_lists: true
space_surround: false
- language_pragmas:
style: vertical
remove_redundant: true
# Remove trailing whitespace
- trailing_whitespace: {}
columns: 100
newline: native
language_extensions:
- BangPatterns
- ConstraintKinds
- DataKinds
- DefaultSignatures
- DeriveAnyClass
- DeriveDataTypeable
- DeriveGeneric
- DerivingStrategies
- DerivingVia
- ExplicitNamespaces
- FlexibleContexts
- FlexibleInstances
- FunctionalDependencies
- GADTs
- GeneralizedNewtypeDeriving
- InstanceSigs
- KindSignatures
- LambdaCase
- MultiParamTypeClasses
- MultiWayIf
- NamedFieldPuns
- NoImplicitPrelude
- OverloadedStrings
- QuasiQuotes
- RecordWildCards
- ScopedTypeVariables
- StandaloneDeriving
- TemplateHaskell
- TupleSections
- TypeApplications
- TypeFamilies
- ViewPatterns
Removing NoImplicitPrelude
from the config allows stylish-haskell
to work again.
+1 for NoImplicitPrelude
.
Same Unknown Extension issue for me as well. Appears for NoImplicitPrelude
as well as NoMonomorphismRestriction
. Any particular reason why this is happening ?
@jaspervdj: thank you very much. When could we expect a release (if not soon, I'd set up a local checkout).
Released in v0.14.3.0
Thank you again. I tested and this problem is fixed. Stylish-haskell works great with type-level (*)
taken from
import GHC.TypeLits
though it chokes at
import GHC.TypeLits (type (*))
with
Warning (stylish-haskell): stylish-haskell failed: <string>:16:48: error:
parse error on input `*'
This is with GHC 9.0.2. Should I report that separately? Is that an error in a stylish-haskell dependency perhaps?
@Mikolaj That seems like a separate issue, please create a new one -- FYI stylish-haskell is currently using GHC 9.2 as a parser (regardless of which GHC it is compiled with).
It accepts
StarIsType
fine, but doesn't acceptNoStarIsType
either in config file nor in file header, sayingand due to that, not accepting