summaryrefslogtreecommitdiff
path: root/compiler/codeGen
diff options
context:
space:
mode:
authorIavor S. Diatchki <iavor.diatchki@gmail.com>2012-01-24 22:11:44 -0800
committerIavor S. Diatchki <iavor.diatchki@gmail.com>2012-01-24 22:11:44 -0800
commit5851f84733f4ef1ee158b911febd753ced619555 (patch)
tree8840092a97618c214810d0fcb52ef17e204dbbea /compiler/codeGen
parent9c1575228173218a3cfa06ddbec3865b12d87713 (diff)
downloadhaskell-5851f84733f4ef1ee158b911febd753ced619555.tar.gz
Add support for type-level "strings".
These are types that look like "this" and "that". They are of kind `Symbol`, defined in module `GHC.TypeLits`. For each type-level symbol `X`, we have a singleton type, `TSymbol X`. The value of the singleton type can be named with the overloaded constant `tSymbol`. Here is an example: tSymbol :: TSymbol "Hello"
Diffstat (limited to 'compiler/codeGen')
-rw-r--r--compiler/codeGen/ClosureInfo.lhs3
-rw-r--r--compiler/codeGen/StgCmmClosure.hs3
2 files changed, 4 insertions, 2 deletions
diff --git a/compiler/codeGen/ClosureInfo.lhs b/compiler/codeGen/ClosureInfo.lhs
index fd27684732..d8fd07fead 100644
--- a/compiler/codeGen/ClosureInfo.lhs
+++ b/compiler/codeGen/ClosureInfo.lhs
@@ -1107,5 +1107,6 @@ getTyDescription ty
getTyLitDescription :: TyLit -> String
getTyLitDescription l =
case l of
- NumberTyLit n -> show n
+ NumTyLit n -> show n
+ StrTyLit n -> show n
\end{code}
diff --git a/compiler/codeGen/StgCmmClosure.hs b/compiler/codeGen/StgCmmClosure.hs
index 7789ae865b..d4ba62c6ca 100644
--- a/compiler/codeGen/StgCmmClosure.hs
+++ b/compiler/codeGen/StgCmmClosure.hs
@@ -873,7 +873,8 @@ getTyDescription ty
getTyLitDescription :: TyLit -> String
getTyLitDescription l =
case l of
- NumberTyLit n -> show n
+ NumTyLit n -> show n
+ StrTyLit n -> show n
--------------------------------------
-- CmmInfoTable-related things