1
Fork 0
This commit is contained in:
Jake Wheat 2013-12-31 11:44:10 +02:00
parent 7cf5275615
commit 9e75fa9365
3 changed files with 4 additions and 7 deletions

View file

@ -1,3 +1,4 @@
> {-# LANGUAGE TupleSections #-}
> -- | This is the module with the parser functions.
> module Language.SQL.SimpleSQL.Parser
@ -275,7 +276,7 @@ operatorname(firstArg keyword0 arg0 keyword1 arg1 etc.)
> -- check we haven't parsed the first
> -- keyword as an identifier
> guard (case (e,kws) of
> (Iden (Name i), ((k,_):_)) | map toLower i == k -> False
> (Iden (Name i), (k,_):_) | map toLower i == k -> False
> _ -> True)
> return e
> fa <- case firstArg of
@ -495,7 +496,7 @@ can be symbols (a + b), single keywords (a and b) or multiple keywords
> ,binarySym "|" E.AssocRight
> ,binaryKeyword "like" E.AssocNone
> ,binaryKeyword "overlaps" E.AssocNone]
> ++ map (flip binaryKeywords E.AssocNone)
> ++ map (`binaryKeywords` E.AssocNone)
> ["not like"
> ,"is similar to"
> ,"is not similar to"

View file

@ -92,7 +92,7 @@
> valueExpr (SpecialOpK nm fs as) =
> name nm <> parens (sep $ catMaybes
> ((fmap valueExpr fs)
> (fmap valueExpr fs
> : map (\(n,e) -> Just (text n <+> valueExpr e)) as))
> valueExpr (PrefixOp f e) = name f <+> valueExpr e

4
TODO
View file

@ -1,9 +1,5 @@
= next release
New fixity code + extensive tests.
check fixity in query expr level?
check fixity in tablerefs
try and use the proper css theme
create a header like in the haddock with simple-sql-parser +
contents link