From: nobuyoshi nakada Date: 2005-08-05T11:20:41+09:00 Subject: Re: ruby-dev summary 26468-26661 Hi, At Fri, 5 Aug 2005 00:29:55 +0900, Eric Mahurin wrote in [ruby-talk:150730]: > Here is my proposal: > > { args : code } > > Even if when you make the args : optional to preserve > compatibility, I think this would be parsable if you treat the > arg list (possibly with default expressions) like a normal > statment except that the delimiter is ":" instead of ";". This > should work because an arg list is a syntactically valid > statement. i.e. > > a=1 > other=[3,4] > a,b=2,*other > > When the lexer finds a ":" instead of a ";" or newline as the > statement delimiter of first statement, it would treat that as > the arg list. Default values can be very long beyond new lines, if it is a block statement or is parenthesized. it seems very confusing and I guess such parser is impossible. Leading sign would be mandatory. -- Nobu Nakada