Changeset 12924 for src/Pugs/AST.hs

Show
Ignore:
Timestamp:
09/01/06 15:11:03 (2 years ago)
Author:
gaal
Message:

* Basic support for parsing Signatures with :().

Only named parameters are parsed, and optionals (incorrectly)
require a '?' even if they have a default value. No parameter
decoration (type constraints, access traits, etc.) is supported
yet. The following forms do work:

:($x:)
:($x)
:($x: $y, $z)
:($x: $y, $z? = 42)
:($x: $y?, $z) # correctly raises a parse error

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/Pugs/AST.hs

    r12721 r12924  
    3939import Pugs.AST.SIO 
    4040import Pugs.AST.Pad 
    41 import Pugs.Val (val, PureStr, PureInt, PureNum, Capt(..), ValCapt, Feed(..), ValFeed, emptyFeed) 
     41import Pugs.Val (val, PureStr, PureInt, PureNum, Capt(..), ValCapt, Feed(..), ValFeed, emptyFeed, Sig(..), SigParam(..), ParamAccess(..), ParamDefault(..)) 
    4242 
    4343{-|