|
CIS 573
Names to avoid using as identifiers in C# or other .NET languages last updated: 08/07/2006 |
It's wise to avoid using class or identifier names found in many namespaces. For instance, do not use the following for a class name:
System Collections Forms UI
Also, for CLR compliance, try to avoid using identifiers that conflict with keywords in any .NET language. The following 145 symbols "to avoid" include the 77 C# keywords, as well as those from other languages such as VB.NET:
AddHandler | AddressOf | Alias | And | Ansi |
As | Assembly | Auto | BitAnd | BitNot |
BitOr | BitXor | Boolean | ByRef | Byte |
ByVal | Call | Case | Catch | CBool |
CByte | CChar | CDate | CDec | CDbl |
Char | CInt | Class | CLng | CObj |
Const | CShort | CSng | CStr | CType |
Date | Decimal | Declare | Default | Delegate |
Dim | Do | Double | Each | Else |
ElseIf | End | Enum | Erase | Error |
Event | Exit | ExternalSource | False | Finally |
For | Friend | Function | Get | GetType |
Goto | Handles | If | Implements | Imports |
In | Inherits | Integer | Interface | Is |
Let | Lib | Like | Long | Loop |
Me | Mod | Module | MustInherit | MustOverride |
MyBase | MyClass | Namespace | New | Next |
Not | Nothing | NotInheritable | NotOverridable | Object |
On | Option | Optional | Or | Overloads |
Overridable | Overrides | ParamArray | Preserve | Private |
Property | Protected | Public | RaiseEvent | ReadOnly |
ReDim | Region | REM | RemoveHandler | Resume |
Return | Select | Set | Shadows | Shared |
Short | Single | Static | Step | Stop |
String | Structure | Sub | SyncLock | Then |
Throw | To | True | Try | TypeOf |
Unicode | Until | Variant | When | While |
With | WithEvents | WriteOnly | Xor | eval |
extends | instanceof | package | var |