[Mono-devel-list] ObjectSpaces + momentum = ORM soup.
Jonathan Gilbert
2a5gjx302 at sneakemail.com
Sat Nov 15 17:17:59 EST 2003
At 03:45 PM 12/11/2003 -0000, you wrote:
[snip]
>Be warned though that some bits are rather shaky and some of the details
>are plain wrong. For example the AstKeyords class has a public field
>called "operator" which isn't accepted by C# for obvious reasons, so I
>can only guess that there's either a clever trick to allow the use of
>operator as a field name or the docs are wrong.
C# allows the use of keywords as identifiers. The '@' prefix (when not to a
string) marks a word that should always be interpreted as an identifier, no
matter what. For instance:
class @class
{
public int @int = 5;
public void @void() { }
public delegate @delegate(int @float);
public @class @operator(@class. at delegate @params) { }
}
Of course, this is rather bad style, but it does allow C# to interoperate
more freely with other languages.
Jonathan
More information about the Mono-devel-list
mailing list