X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fparser%2FLexer.x;h=4ce83047fc21e84210a5b7b409a3b7c9163dafa8;hp=4e9617602280fe2cf5dac5fb4b032e3fdf9124b1;hb=847d3977929216f2484ed6ae33112b74fc86776a;hpb=e553a60151dc282c8b8c201871212cba0c3bf2a0 diff --git a/compiler/parser/Lexer.x b/compiler/parser/Lexer.x index 4e96176..4ce8304 100644 --- a/compiler/parser/Lexer.x +++ b/compiler/parser/Lexer.x @@ -1794,25 +1794,9 @@ alternativeLayoutRule flags = testBit flags alternativeLayoutRuleBit -- PState for parsing options pragmas -- pragState :: DynFlags -> StringBuffer -> SrcLoc -> PState -pragState dynflags buf loc = - PState { - buffer = buf, - messages = emptyMessages, - dflags = dynflags, - last_loc = mkSrcSpan loc loc, - last_len = 0, - loc = loc, - extsBitmap = 0, - context = [], - lex_state = [bol, option_prags, 0], - alr_pending_implicit_tokens = [], - alr_next_token = Nothing, - alr_last_loc = noSrcSpan, - alr_context = [], - alr_expecting_ocurly = Nothing, - alr_justClosedExplicitLetBlock = False - } - +pragState dynflags buf loc = (mkPState dynflags buf loc) { + lex_state = [bol, option_prags, 0] + } -- create a parse state --