Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel de Icaza <miguel@gnome.org>2002-03-01 08:24:34 +0300
committerMiguel de Icaza <miguel@gnome.org>2002-03-01 08:24:34 +0300
commitf00566a71f01320f5cac5e7dd80f3d3705d8b2d0 (patch)
tree414dc452fdbeb8b335f30b180f032c57f931ebd1 /mcs/class/README
parent2c72e5163565732e8dd1e128b7a2bd4b16787645 (diff)
Updated guildeines
svn path=/trunk/mcs/; revision=2794
Diffstat (limited to 'mcs/class/README')
-rw-r--r--mcs/class/README24
1 files changed, 18 insertions, 6 deletions
diff --git a/mcs/class/README b/mcs/class/README
index 00320a50792..9e0a280b865 100644
--- a/mcs/class/README
+++ b/mcs/class/README
@@ -34,7 +34,7 @@ the restricted dll found in the same directory.
[MonoTODO]
int MyFunction ()
{
- throw new Exception ("Unimplemented");
+ throw new NotImplementedException ();
}
* Tagging buggy code
@@ -99,16 +99,17 @@ the restricted dll found in the same directory.
A few guidelines:
* Use a space before an opening parenthesis when calling
- functions, like this:
+ functions, or indexing, like this:
method (a);
+ b [10];
* Do not put a space after the opening parenthesis and the
closing one, ie:
- good: method (a);
+ good: method (a); array [10];
- bad: method ( a );
+ bad: method ( a ); array[ 10 ];
* Inside a code block, put the opening brace on the same line
as the statement:
@@ -150,8 +151,9 @@ the restricted dll found in the same directory.
void Method () {
}
- * Properties are an exception, keep the brace on the same line
- as the property declaration. Rationale: this makes it visually
+ * Properties and indexers are an exception, keep the
+ brace on the same line as the property declaration.
+ Rationale: this makes it visually
simple to distinguish them.
good:
@@ -197,6 +199,16 @@ the restricted dll found in the same directory.
* If you are modyfing someone else's code, and your contribution
is significant, please add yourself to the Authors list.
+ * Switch statements have the case at the same indentation as the
+ switch:
+
+ switch (x) {
+ case 'a':
+ ...
+ case 'b':
+ ...
+ }
+
Here are a couple of examples:
class X : Y {