CurryInfo: currypp-3.2.0 / CPP.ICode.Parser.SQL.Scanner.scan

definition: Info
 
scan :: String -> [Token]
scan chs =
   case chs of
      ""            -> []
      ('*':cs)      -> Asterix : scan cs
      ('(':cs)      -> LParen : scan cs
      (')':cs)      -> RParen : scan cs
      (',':cs)      -> Comma : scan cs
      (';':cs)      -> Semi : scan cs
      ('.':cs)      -> Stop : scan cs
      ('!':'=': cs) -> (BinOp Uneq) : scan cs
      ('=':cs)      -> (BinOp Equal) : scan cs
      ('{':cs)      -> readEmbedExp cs
      ('<':cs)      -> readLessOp cs
      ('>':cs)      -> readGreaterOp cs
      ('\"':cs)     -> readVarString cs
      ('\'':cs)     -> readVarChar cs
      (' ':cs)      -> scan cs
      ('\n':cs)     -> scan cs
      _             -> if (isDigit (head chs) || (head chs) == '-')
                         then (getNumberOrDate nStr) : scan nRs
                         else if (isAlpha (head chs))
                                 then (specialOrIdent s) : scan rs
                                 else (Unexpected (head chs)) : scan (tail chs)
  where (nStr, nRs) = span isDigitOrNChar chs
        (s,rs)      = span isAlphaNumUnderScore chs
demand: Info
 argument 1
deterministic: Info
 deterministic operation
documentation: Info
 
Scans an SQL-statement - returning it as list of Token.
@param chs - the statement as string
@return the statement as list of token
failfree: Info
 <FAILING>
indeterministic: Info
 referentially transparent operation
infix: Info
 no fixity defined
iotype: Info
 {({[]}) |-> {[]} || ({:}) |-> {:,[]}}
name: Info
 scan
precedence: Info
 no precedence defined
result-values: Info
 {:,[]}
signature: Info
 String -> [CPP.ICode.Parser.SQL.Token.Token]
solution-complete: Info
 operation might suspend on free variables
terminating: Info
 possibly non-terminating
totally-defined: Info
 possibly non-reducible on same data term