In "def foo(x, y)" the types for "x" and "y" are dynamic. However, since the default type for arguments is not dynamic? (note the question mark for "nilable"), you cannot pass nil or a nilable expression to the arguments.
But my original intent was that untyped arguments be as flexible and late bound as possible. So I'm planning to change the default argument type to dynamic?. Of course, if that disagrees with your needs, you can explicitly use the dynamic type as in "def foo(x as dynamic, y as dynamic)".
This would also affect untyped vars and untyped properties.
If you have any feedback, please speak up soon.
Thanks,
Chuck
Forums
Default type for arguments
3 posts
• Page 1 of 1
Re: Default type for arguments
This is done in development.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
Re: Default type for arguments
Very interesting idea... this is a very flexible approach, maybe the most flexible....
- relez
- Posts: 69
3 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 106 guests