diff --git a/fco2/Parse.hs b/fco2/Parse.hs index fc04a90..bd87cea 100644 --- a/fco2/Parse.hs +++ b/fco2/Parse.hs @@ -785,8 +785,6 @@ expression <|> do { m <- md; sMOSTPOS; t <- dataType; return $ A.MostPos m t } <|> do { m <- md; sMOSTNEG; t <- dataType; return $ A.MostNeg m t } <|> sizeExpr - <|> do { m <- md; sTRUE; return $ A.True m } - <|> do { m <- md; sFALSE; return $ A.False m } <|> do m <- md (l, o) <- tryVV operand dyadicOperator t <- typeOfExpression l @@ -940,6 +938,8 @@ operandNotTable' do { o <- noTypeContext operand; sRightR; return $ A.BytesInExpr m o } <|> do { t <- dataType; sRightR; return $ A.BytesInType m t } <|> do { m <- md; sOFFSETOF; sLeftR; t <- dataType; sComma; f <- fieldName; sRightR; return $ A.OffsetOf m t f } + <|> do { m <- md; sTRUE; return $ A.True m } + <|> do { m <- md; sFALSE; return $ A.False m } "operand other than table'" --}}} --{{{ variables, channels, timers, ports diff --git a/fco2/SYNTAX b/fco2/SYNTAX index da689c1..c9d1aa3 100644 --- a/fco2/SYNTAX +++ b/fco2/SYNTAX @@ -12,9 +12,10 @@ x ! y is ambiguous. << and >> are missing from dyadic.operator. --- Things that Parse.hs currently implements as per the spec +"b = TRUE" isn't a valid expression (occ21 allows it, and it's used in cglib) +-- moved TRUE/FALSE into operand. -"b = TRUE" isn't a valid expression (occ21 allows it, and it's used in cglib). +-- Things that Parse.hs currently implements as per the spec PROCESSOR is permitted as a process, anywhere.