4 Errors in the Mono C# compiler use the same codes as the
5 Microsoft C# compiler, the listing of the errors on it lives
8 http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cscomp/html/vctbsCompilerErrorsSC0001ThroughSC9999.asp
12 Error tests are stored in files with the format:
14 csXXXX.cs for the first error.
15 csXXXX-2.cs for the second way to trigger the error.
16 csXXXX-n.cs for subsequent ways of triggering the error.
18 The file should start with two inline commented lines.
19 The first one contains a little description of the error,
20 the second line declares the line where the error occurs.
22 You should not copy Microsoft's examples or documentation
23 text. You will need to write your own.
27 // cs0057.cs: Inconsistent accessibility. Parameter type is less accessible than operator.
30 There should not be more than one error per tests. Each test
31 should only contain one error.
33 Then you have to add the file to the CVS and commit it.
35 The next thing is to write a short text file with a little
36 description of what the error is and what it's necessary
37 to be done to solve it.
41 If you need to run error test with some special option(s),
42 use following syntax in your error test file.
44 // cs0193.cs: * or -> operator can only be applied to pointer types.
46 // Compiler options: -unsafe
50 In case that your error test depends on the library or other C# file.
51 Create separate file with same name as your error test name except
52 first two letters which are uppercased. And then add this file to
57 Many of the errors in this test suite are not tested for by MCS. To cope
58 with this, we have a list of failures, so that someone running the test
59 can know if they have caused any regressions.
61 In this model there are two types of regressions:
62 * Incorrect error -- When mcs emits an error, but it is different
63 than the one CSC emits.
65 * No error -- When mcs incorrectly compiles an invalid file.
67 `Incorrect error' regressions should be listed in mcs-expect-wrong-error.
68 `No error' regressiions should be listed in mcs-expect-no-error.
70 If you fix a bug and thus remove a regression, be sure to remove the file
71 from the failures list!