Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- From: Robert Giesecke <spam@xxxxxxxxx>
- Date: Wed, 29 Aug 2007 09:15:40 +0200
Marco Caspers wrote:
>
But i see an issue with the Default function you described.
1). default (note lower case d) is already a reserved word in C#
The is exactly what the "default" keyword in C# is used for, so how could there be any problem with it?
2). Many ASP.NET developers have a Default page (note the capital D).
Having a Default page, means that there is a Default.pas file.
That will create conflicts. In fact, it could mean that some projects containing a Default.pas
won't compile at all because Default is now defined more than once...
In Chrome, you'd call your class _Default while the page itself can be named WhatEverYouLike.aspx.
From my point of vieuw, this doesn't look like a good naming descision.
Every generic-enabled CLR language, that I have seen so far, used a compiler magic function called "default" to wrap Activator.CreateInstance<T>().
Can't see anything evil in it.
.
- Follow-Ups:
- Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- From: Marco Caspers
- Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- References:
- Highlander2 Beta-blogging: Generics in Delphi for .NET
- From: Hallvard Vassbotn
- Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- From: Marco Caspers
- Highlander2 Beta-blogging: Generics in Delphi for .NET
- Prev by Date: Re: A very good blog about the Delphi 2007 Help Issue
- Next by Date: Re: A very good blog about the Delphi 2007 Help Issue
- Previous by thread: Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- Next by thread: Re: Highlander2 Beta-blogging: Generics in Delphi for .NET
- Index(es):
Relevant Pages
|