warning(s) for using stolen syntax that's not currently enabled
Turning on -fglasgow-exts
makes f x = id$x
break. I propose having a flag to warn about things like this, enabled by -Wall
. To be precise, "stolen syntax" is syntax that means something valid in (usually) Haskell98 and something different with some extension enabled. If there are syntax-stealing extensions implemented by other non-GHC compilers, we may want to warn about those too. (This includes all keywords, possibly other words like "forall", "exists", "family", unicode symbols for ->
and others...)
If anyone actually agrees on or implements a (optional) change to unary-minus, this would subsume the warning aspects of #1318 (closed).
Trac metadata
Trac field | Value |
---|---|
Version | 6.6.1 |
Type | FeatureRequest |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | Unknown |
Architecture | Unknown |