1
1
module Text.Parsing.Parser.Token where
2
-
3
- import Prelude
2
+
3
+ import Prelude
4
4
5
5
import Data.String
6
6
7
7
import Control.Monad.State.Class
8
8
import Control.Monad.Error.Class
9
9
10
- import Control.Applicative
11
-
12
10
import Text.Parsing.Parser
13
11
import Text.Parsing.Parser.String
14
12
import Text.Parsing.Parser.Combinators
15
-
16
- type LanguageDef s m = {
13
+
14
+ type LanguageDef s m = {
17
15
commentStart :: String ,
18
16
commentEnd :: String ,
19
17
commentLine :: String ,
@@ -26,7 +24,7 @@ type LanguageDef s m = {
26
24
reservedOpNames :: [String ],
27
25
caseSensitive :: Boolean
28
26
}
29
-
27
+
30
28
type TokenParser s m = {
31
29
identifier :: ParserT s m String ,
32
30
reserved :: String -> ParserT s m String ,
@@ -50,15 +48,15 @@ type TokenParser s m = {
50
48
brackets :: forall a . ParserT s m a -> ParserT s m a ,
51
49
semi :: ParserT s m String ,
52
50
comma :: ParserT s m String ,
53
- colon :: ParserT s m String ,
51
+ colon :: ParserT s m String ,
54
52
dot :: ParserT s m String ,
55
53
semiSep :: forall a . ParserT s m a -> ParserT s m [a ],
56
54
semiSep1 :: forall a . ParserT s m a -> ParserT s m [a ],
57
55
commaSep :: forall a . ParserT s m a -> ParserT s m [a ],
58
56
commaSep1 :: forall a . ParserT s m a -> ParserT s m [a ]
59
57
}
60
58
61
- {-
59
+ {-
62
60
-- Port in progress
63
61
makeTokenParser :: LanguageDef s m -> TokenParser s m
64
62
makeTokenParser languageDef
@@ -436,5 +434,5 @@ makeTokenParser languageDef
436
434
<?> "end of comment"
437
435
where
438
436
startEnd = nub (commentEnd languageDef ++ commentStart languageDef)
439
-
440
- -}
437
+
438
+ -}
0 commit comments