Wiki
Show
Ignore:
Timestamp:
11/28/08 20:11:01 (3 years ago)
Author:
Chuck.Esterbrook
Message:

Added streams to the language. For example, int* or String*

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • cobra/trunk/Source/CobraParser.cobra

    r1761 r1781  
    32523252            t = ArrayTypeIdentifier(bracket, t) 
    32533253 
    3254         # check for 'optional' aka 'can be nil' 
    3255         question = .optional('QUESTION') 
    3256         if question 
    3257             t = NilableTypeIdentifier(question, t) 
     3254        while true 
     3255            # check for 'optional' aka 'can be nil' 
     3256            if .optional('QUESTION') 
     3257                t = NilableTypeIdentifier(.last, t) 
     3258     
     3259            # check for 'stream' aka 'multiple' aka 'zero or more' aka 'enumerable' 
     3260            else if .optional('STAR') 
     3261                t = StreamTypeIdentifier(.last, t) 
     3262 
     3263            else 
     3264                break 
    32583265 
    32593266        return t to !