[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [DotGNU]Generic IL Examples
From: |
Rhys Weatherley |
Subject: |
Re: [DotGNU]Generic IL Examples |
Date: |
Wed, 19 Feb 2003 17:38:25 +1000 |
User-agent: |
KMail/1.4.3 |
On Wednesday 19 February 2003 05:05 pm, Fergus Henderson wrote:
> I was thinking
>
> callvirt void class Stack<!V>::Push(!V)
> callvirt void class Stack<!T>::Push(!T)
>
> i.e. keep the "!" and "!!" prefixes, but just use names instead of numbers.
> [...]
> So another possibility would be to use a slightly different syntax for
> names that refer to classes other than the current scope. For example,
> perhaps those could use "~V" rather than "!V".
>
> Then it would be
>
> callvirt void class Stack<!V>::Push(~V)
> callvirt void class Stack<!T>::Push(~T)
I'm loath to break compatibility with Gyro at this stage, but there may still
be something simple that we can do. Perhaps a compromise?
callvirt void class Stack<!V>::Push(!0)
callvirt void class Stack<!T>::Push(!0)
i.e. names can be used where the scope is unambiguous. In the case of method
signatures, the numbers can be read as "parameter 0" of the immediately
enclosing method invocation. The user can quickly see that this is "V".
Cheers,
Rhys.
Re: [DotGNU]Generic IL Examples, James Michael DuPont, 2003/02/19