diff options
| author | simonmar <unknown> | 2003-09-24 13:04:58 +0000 |
|---|---|---|
| committer | simonmar <unknown> | 2003-09-24 13:04:58 +0000 |
| commit | 38ef36af81c7fe05f12ead2bb3613cff208d81fe (patch) | |
| tree | 4420985f074850909f2fc984c62dcedb1f00566a /ghc/compiler/parser | |
| parent | 8f57c3c1812681ef2a57f7982b81c3123e90a2ca (diff) | |
| download | haskell-38ef36af81c7fe05f12ead2bb3613cff208d81fe.tar.gz | |
[project @ 2003-09-24 13:04:45 by simonmar]
The concensus seems to be that 'with' should go away now, after its
customary period of deprecation. Hugs has already removed it, so
we're following suit.
Diffstat (limited to 'ghc/compiler/parser')
| -rw-r--r-- | ghc/compiler/parser/Lexer.x | 7 | ||||
| -rw-r--r-- | ghc/compiler/parser/Parser.y | 8 |
2 files changed, 3 insertions, 12 deletions
diff --git a/ghc/compiler/parser/Lexer.x b/ghc/compiler/parser/Lexer.x index 264b7249bb..997a7d7d88 100644 --- a/ghc/compiler/parser/Lexer.x +++ b/ghc/compiler/parser/Lexer.x @@ -334,7 +334,6 @@ data Token__ | ITsafe | ITthreadsafe | ITunsafe - | ITwith | ITstdcallconv | ITccallconv | ITdotnet @@ -455,7 +454,6 @@ isSpecial ITdynamic = True isSpecial ITsafe = True isSpecial ITthreadsafe = True isSpecial ITunsafe = True -isSpecial ITwith = True isSpecial ITccallconv = True isSpecial ITstdcallconv = True isSpecial ITmdo = True @@ -514,8 +512,6 @@ reservedWordsFM = listToUFM $ ( "ccall", ITccallconv, bit ffiBit), ( "dotnet", ITdotnet, bit ffiBit), - ( "with", ITwith, bit withBit), - ( "rec", ITrec, bit arrowsBit), ( "proc", ITproc, bit arrowsBit) ] @@ -1187,7 +1183,6 @@ glaExtsBit, ffiBit, parrBit :: Int glaExtsBit = 0 ffiBit = 1 parrBit = 2 -withBit = 3 arrowsBit = 4 thBit = 5 ipBit = 6 @@ -1195,7 +1190,6 @@ ipBit = 6 glaExtsEnabled, ffiEnabled, parrEnabled :: Int -> Bool glaExtsEnabled flags = testBit flags glaExtsBit ffiEnabled flags = testBit flags ffiBit -withEnabled flags = testBit flags withBit parrEnabled flags = testBit flags parrBit arrowsEnabled flags = testBit flags arrowsBit thEnabled flags = testBit flags thBit @@ -1218,7 +1212,6 @@ mkPState buf loc flags = where bitmap = glaExtsBit `setBitIf` dopt Opt_GlasgowExts flags .|. ffiBit `setBitIf` dopt Opt_FFI flags - .|. withBit `setBitIf` dopt Opt_With flags .|. parrBit `setBitIf` dopt Opt_PArr flags .|. arrowsBit `setBitIf` dopt Opt_Arrows flags .|. thBit `setBitIf` dopt Opt_TH flags diff --git a/ghc/compiler/parser/Parser.y b/ghc/compiler/parser/Parser.y index 194e457354..7976b1b25f 100644 --- a/ghc/compiler/parser/Parser.y +++ b/ghc/compiler/parser/Parser.y @@ -1,6 +1,6 @@ {- -*-haskell-*- ----------------------------------------------------------------------------- -$Id: Parser.y,v 1.124 2003/09/23 14:33:02 simonmar Exp $ +$Id: Parser.y,v 1.125 2003/09/24 13:04:51 simonmar Exp $ Haskell grammar. @@ -127,7 +127,6 @@ Conflicts: 29 shift/reduce, [SDM 19/9/2002] 'safe' { T _ _ ITsafe } 'threadsafe' { T _ _ ITthreadsafe } 'unsafe' { T _ _ ITunsafe } - 'with' { T _ _ ITwith } 'mdo' { T _ _ ITmdo } 'stdcall' { T _ _ ITstdcallconv } 'ccall' { T _ _ ITccallconv } @@ -461,8 +460,8 @@ where :: { [RdrBinding] } -- Reversed binds :: { RdrNameHsBinds } -- May have implicit parameters : decllist { cvBinds $1 } - | '{' dbinds '}' { IPBinds $2 False{-not with-} } - | vocurly dbinds close { IPBinds $2 False{-not with-} } + | '{' dbinds '}' { IPBinds $2 } + | vocurly dbinds close { IPBinds $2 } wherebinds :: { RdrNameHsBinds } -- May have implicit parameters : 'where' binds { $2 } @@ -909,7 +908,6 @@ sigdecl :: { RdrBinding } exp :: { RdrNameHsExpr } : infixexp '::' sigtype { ExprWithTySig $1 $3 } - | infixexp 'with' dbinding { HsLet (IPBinds $3 True{-not a let-}) $1 } | fexp srcloc '-<' exp { HsArrApp $1 $4 placeHolderType HsFirstOrderApp True $2 } | fexp srcloc '>-' exp { HsArrApp $4 $1 placeHolderType HsFirstOrderApp False $2 } | fexp srcloc '-<<' exp { HsArrApp $1 $4 placeHolderType HsHigherOrderApp True $2 } |
