summaryrefslogtreecommitdiff
path: root/compiler/GHC/Parser/Annotation.hs
diff options
context:
space:
mode:
authorAlan Zimmerman <alan.zimm@gmail.com>2020-10-04 20:46:41 +0100
committerAlan Zimmerman <alan.zimm@gmail.com>2020-10-20 08:35:34 +0100
commitea736839d85594c95490dcf02d3325c2bbc68f33 (patch)
tree6f6c0335e216f67b63caf9e4a46d3e5bb6e852af /compiler/GHC/Parser/Annotation.hs
parent59b08a5d192e102f66a6d9260cc8466d7428cffe (diff)
downloadhaskell-wip/az/unicode-hsscaled.tar.gz
API Annotations: Keep track of unicode for linear arrow notationwip/az/unicode-hsscaled
The linear arrow can be parsed as `%1 ->` or a direct single token unicode equivalent. Make sure that this distinction is captured in the parsed AST by using IsUnicodeSyntax where it appears, and introduce a new API Annotation, AnnMult to represent its location when unicode is not used. Updated haddock submodule
Diffstat (limited to 'compiler/GHC/Parser/Annotation.hs')
-rw-r--r--compiler/GHC/Parser/Annotation.hs1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/GHC/Parser/Annotation.hs b/compiler/GHC/Parser/Annotation.hs
index 0cbf44296f..a3cbc92308 100644
--- a/compiler/GHC/Parser/Annotation.hs
+++ b/compiler/GHC/Parser/Annotation.hs
@@ -301,6 +301,7 @@ data AnnKeywordId
| AnnMdo
| AnnMinus -- ^ '-'
| AnnModule
+ | AnnMult -- ^ '%1'
| AnnNewtype
| AnnName -- ^ where a name loses its location in the AST, this carries it
| AnnOf