cleol
[mcs.git] / tests / test-xml-022.cs
blobb7eb5aacd4bd422c1362879b3951e41b0bd99265
1 // Compiler options: -doc:xml-022.xml
2 //
3 // Combined tests (for detecting incorrect markup targeting).
4 //
5 using System;
7 /// <summary>
8 /// xml comment is not allowed here.
9 /// </summary>
10 namespace Testing
12 /// <summary>
13 /// </incorrect>
14 public class Test2
16 /**
17 another documentation style (Java-mimic)
19 public static void Foo ()
21 /// here is an extraneous comment
24 public static void Main ()
29 /// testing indentation <summary> test test ;-)
30 /// comment for struct
31 /// </summary>
32 public struct StructTest
36 /// <summary>
37 /// comment for interface
38 /// </summary>
39 public interface InterfaceTest
43 /// <summary>
44 /// comment for enum type
45 /// </summary>
46 public enum EnumTest
48 /// <summary>
49 /// comment for enum field
50 /// </summary>
51 Foo,
52 Bar,
55 /// <summary>
56 /// comment for dummy type
57 /// </summary>
58 public class Dummy {}
60 /// <summary>
61 /// comment for delegate type
62 /// </summary>
63 public delegate void MyDelegate (object o, EventArgs e);
65 /// <summary>
66 /// description for class Test
67 /// </summary>
68 public class Test
70 /// comment for const declaration
71 const string Constant = "CONSTANT STRING";
73 /// comment for public field
74 public string BadPublicField;
76 /// comment for private field
77 private string PrivateField;
79 /// comment for public property
80 public string PublicProperty {
81 /// comment for private property getter
82 get { return null; }
85 /// comment for private property
86 private string PrivateProperty {
87 get { return null; }
88 /// comment for private property setter
89 set { }
92 int x;
94 /// public event EventHandler MyEvent ;-)
95 public event EventHandler MyEvent;
97 int y;
99 /// here is a documentation!!!
100 public static void Foo ()
104 /// here is a documentation with parameters
105 public static void Foo (long l, Test t, System.Collections.ArrayList al)
109 /// comment for indexer
110 public string this [int i] {
111 get { return null; }
114 /// comment for indexer wit multiple parameters
115 public string this [int i, Test t] {
116 get { return null; }
119 /// <summary>
120 /// comment for unary operator
121 /// </summary>
122 public static bool operator ! (Test t)
124 return false;
127 /// <summary>
128 /// comment for binary operator
129 /// </summary>
130 public static int operator + (Test t, int b)
132 return b;
135 /// comment for destructor
136 ~Test ()
140 /// comment for .ctor()
141 public Test ()
145 /// comment for .ctor(string arg, string [] args)
146 public Test (string arg, string [] args)
150 /// comment for internal class
151 public class InternalClass
155 /// comment for internal struct
156 public struct InternalStruct