equal
deleted
inserted
replaced
119 try $ string "DEFINE" |
119 try $ string "DEFINE" |
120 spaces |
120 spaces |
121 i <- identifier |
121 i <- identifier |
122 d <- ((string ":=" >> return ())<|> spaces) >> many (noneOf "}") |
122 d <- ((string ":=" >> return ())<|> spaces) >> many (noneOf "}") |
123 char '}' |
123 char '}' |
124 updateState $ \(m, b) -> (if and b then Map.insert i d m else m, b) |
124 updateState $ \(m, b) -> (if (and b) && (head i /= '_') then Map.insert i d m else m, b) |
125 return "" |
125 return "" |
126 replace s = do |
126 replace s = do |
127 (m, _) <- getState |
127 (m, _) <- getState |
128 return $ Map.findWithDefault s s m |
128 return $ Map.findWithDefault s s m |
129 |
129 |