summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Compile/Compute
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/GF/Compile/Compute')
-rw-r--r--src/compiler/GF/Compile/Compute/AppPredefined.hs2
-rw-r--r--src/compiler/GF/Compile/Compute/Predef.hs3
-rw-r--r--src/compiler/GF/Compile/Compute/Value.hs2
3 files changed, 5 insertions, 2 deletions
diff --git a/src/compiler/GF/Compile/Compute/AppPredefined.hs b/src/compiler/GF/Compile/Compute/AppPredefined.hs
index 869052e0a..861a74a89 100644
--- a/src/compiler/GF/Compile/Compute/AppPredefined.hs
+++ b/src/compiler/GF/Compile/Compute/AppPredefined.hs
@@ -84,6 +84,8 @@ primitives = Map.fromList
[(Explicit,varL,typeType),(Explicit,identW,mkFunType [typeStr] typeStr),(Explicit,identW,Vr varL)] (Vr varL) []))) Nothing)
, (cNonExist , ResOper (Just (noLoc (mkProd -- Str
[] typeStr []))) Nothing)
+ , (cBIND , ResOper (Just (noLoc (mkProd -- Str
+ [] typeStr []))) Nothing)
]
where
fun from to = oper (mkFunType from to)
diff --git a/src/compiler/GF/Compile/Compute/Predef.hs b/src/compiler/GF/Compile/Compute/Predef.hs
index 11c4002b8..b8b7f7c77 100644
--- a/src/compiler/GF/Compile/Compute/Predef.hs
+++ b/src/compiler/GF/Compile/Compute/Predef.hs
@@ -78,7 +78,7 @@ predefList =
(cError,Error),
-- Canonical values:
(cPBool,PBool),(cPFalse,PFalse),(cPTrue,PTrue),(cInt,Int),
- (cInts,Ints),(cNonExist,NonExist)]
+ (cInts,Ints),(cNonExist,NonExist),(cBIND,BIND)]
--- add more functions!!!
delta f vs =
@@ -106,6 +106,7 @@ delta f vs =
PFalse -> canonical
PTrue -> canonical
NonExist-> canonical
+ BIND -> canonical
where
canonical = delay
delay = return (VApp f vs) -- wrong number of arguments
diff --git a/src/compiler/GF/Compile/Compute/Value.hs b/src/compiler/GF/Compile/Compute/Value.hs
index 7dbaaa193..e72b06778 100644
--- a/src/compiler/GF/Compile/Compute/Value.hs
+++ b/src/compiler/GF/Compile/Compute/Value.hs
@@ -51,5 +51,5 @@ data Predefined = Drop | Take | Tk | Dp | EqStr | Occur | Occurs | ToUpper
{- | Show | Read | ToStr | MapStr | EqVal -}
| Error
-- Canonical values below:
- | PBool | PFalse | PTrue | Int | Ints | NonExist
+ | PBool | PFalse | PTrue | Int | Ints | NonExist | BIND
deriving (Show,Eq,Ord,Ix,Bounded,Enum)