~ubuntu-branches/ubuntu/oneiric/monodevelop/oneiric-updates

« back to all changes in this revision

Viewing changes to src/core/NRefactory/Project/Src/Ast/Generated.cs

  • Committer: Bazaar Package Importer
  • Author(s): Jo Shields
  • Date: 2009-02-18 08:40:51 UTC
  • mfrom: (1.2.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090218084051-gh8m6ukvokbwj7cf
Tags: 1.9.2+dfsg-1ubuntu1
* Merge from Debian Experimental (LP: #330519), remaining Ubuntu changes:
  + debian/control:
    - Update for Gnome# 2.24
    - Add libmono-cairo1.0-cil to build-deps to fool pkg-config check

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
//------------------------------------------------------------------------------
2
2
// <auto-generated>
3
3
//     This code was generated by a tool.
4
 
//     Runtime Version:2.0.50727.42
 
4
//     Runtime Version:2.0.50727.1434
5
5
//
6
6
//     Changes to this file may cause incorrect behavior and will be lost if
7
7
//     the code is regenerated.
136
136
                
137
137
                List<Expression> arguments;
138
138
                
139
 
                ArrayInitializerExpression arrayInitializer;
 
139
                CollectionInitializerExpression arrayInitializer;
140
140
                
141
141
                public TypeReference CreateType {
142
142
                        get {
156
156
                        }
157
157
                }
158
158
                
159
 
                public ArrayInitializerExpression ArrayInitializer {
 
159
                public CollectionInitializerExpression ArrayInitializer {
160
160
                        get {
161
161
                                return arrayInitializer;
162
162
                        }
163
163
                        set {
164
 
                                arrayInitializer = value ?? ArrayInitializerExpression.Null;
 
164
                                arrayInitializer = value ?? CollectionInitializerExpression.Null;
165
165
                                if (!arrayInitializer.IsNull) arrayInitializer.Parent = this;
166
166
                        }
167
167
                }
169
169
                public ArrayCreateExpression(TypeReference createType) {
170
170
                        CreateType = createType;
171
171
                        arguments = new List<Expression>();
172
 
                        arrayInitializer = ArrayInitializerExpression.Null;
 
172
                        arrayInitializer = CollectionInitializerExpression.Null;
173
173
                }
174
174
                
175
175
                public ArrayCreateExpression(TypeReference createType, List<Expression> arguments) {
176
176
                        CreateType = createType;
177
177
                        Arguments = arguments;
178
 
                        arrayInitializer = ArrayInitializerExpression.Null;
 
178
                        arrayInitializer = CollectionInitializerExpression.Null;
179
179
                }
180
180
                
181
 
                public ArrayCreateExpression(TypeReference createType, ArrayInitializerExpression arrayInitializer) {
 
181
                public ArrayCreateExpression(TypeReference createType, CollectionInitializerExpression arrayInitializer) {
182
182
                        CreateType = createType;
183
183
                        ArrayInitializer = arrayInitializer;
184
184
                        arguments = new List<Expression>();
185
185
                }
186
186
                
 
187
                public bool IsImplicitlyTyped {
 
188
                        get {
 
189
                                return createType.IsNull || string.IsNullOrEmpty(createType.Type);
 
190
                        }
 
191
                }
 
192
                
187
193
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
188
194
                        return visitor.VisitArrayCreateExpression(this, data);
189
195
                }
193
199
                }
194
200
        }
195
201
        
196
 
        public class ArrayInitializerExpression : Expression {
197
 
                
198
 
                List<Expression> createExpressions;
199
 
                
200
 
                public List<Expression> CreateExpressions {
201
 
                        get {
202
 
                                return createExpressions;
203
 
                        }
204
 
                        set {
205
 
                                createExpressions = value ?? new List<Expression>();
206
 
                        }
207
 
                }
208
 
                
209
 
                public ArrayInitializerExpression() {
210
 
                        createExpressions = new List<Expression>();
211
 
                }
212
 
                
213
 
                public ArrayInitializerExpression(List<Expression> createExpressions) {
214
 
                        CreateExpressions = createExpressions;
215
 
                }
216
 
                
217
 
                public new static ArrayInitializerExpression Null {
218
 
                        get {
219
 
                                return NullArrayInitializerExpression.Instance;
220
 
                        }
221
 
                }
222
 
                
223
 
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
224
 
                        return visitor.VisitArrayInitializerExpression(this, data);
225
 
                }
226
 
                
227
 
                public override string ToString() {
228
 
                        return string.Format("[ArrayInitializerExpression CreateExpressions={0}]", GetCollectionString(CreateExpressions));
229
 
                }
230
 
        }
231
 
        
232
 
        public class NullArrayInitializerExpression : ArrayInitializerExpression {
233
 
                
234
 
                private NullArrayInitializerExpression() {
235
 
                }
236
 
                
237
 
                static NullArrayInitializerExpression instance = new NullArrayInitializerExpression();
238
 
                
239
 
                public static NullArrayInitializerExpression Instance {
240
 
                        get {
241
 
                                return instance;
242
 
                        }
243
 
                }
244
 
                
245
 
                public override bool IsNull {
246
 
                        get {
247
 
                                return true;
248
 
                        }
249
 
                }
250
 
                
251
 
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
252
 
                        return null;
253
 
                }
254
 
                
255
 
                public override string ToString() {
256
 
                        return "[NullArrayInitializerExpression]";
257
 
                }
258
 
        }
259
 
        
260
202
        public class AssignmentExpression : Expression {
261
203
                
262
204
                Expression left;
344
286
                        }
345
287
                }
346
288
                
 
289
                public Attribute() {
 
290
                        name = "";
 
291
                        positionalArguments = new List<Expression>();
 
292
                        namedArguments = new List<NamedArgumentExpression>();
 
293
                }
 
294
                
347
295
                public Attribute(string name, List<Expression> positionalArguments, List<NamedArgumentExpression> namedArguments) {
348
296
                        Name = name;
349
297
                        PositionalArguments = positionalArguments;
383
331
                        }
384
332
                }
385
333
                
 
334
                protected AttributedNode() {
 
335
                        attributes = new List<AttributeSection>();
 
336
                }
 
337
                
386
338
                protected AttributedNode(List<AttributeSection> attributes) {
387
339
                        Attributes = attributes;
388
340
                }
417
369
                        }
418
370
                }
419
371
                
420
 
                public AttributeSection(string attributeTarget, List<ICSharpCode.NRefactory.Ast.Attribute> attributes) {
421
 
                        AttributeTarget = attributeTarget;
422
 
                        Attributes = attributes;
 
372
                public AttributeSection() {
 
373
                        attributeTarget = "";
 
374
                        attributes = new List<Attribute>();
423
375
                }
424
376
                
425
377
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
787
739
                }
788
740
        }
789
741
        
 
742
        public class CollectionInitializerExpression : Expression {
 
743
                
 
744
                List<Expression> createExpressions;
 
745
                
 
746
                public List<Expression> CreateExpressions {
 
747
                        get {
 
748
                                return createExpressions;
 
749
                        }
 
750
                        set {
 
751
                                createExpressions = value ?? new List<Expression>();
 
752
                        }
 
753
                }
 
754
                
 
755
                public CollectionInitializerExpression() {
 
756
                        createExpressions = new List<Expression>();
 
757
                }
 
758
                
 
759
                public CollectionInitializerExpression(List<Expression> createExpressions) {
 
760
                        CreateExpressions = createExpressions;
 
761
                }
 
762
                
 
763
                public new static CollectionInitializerExpression Null {
 
764
                        get {
 
765
                                return NullCollectionInitializerExpression.Instance;
 
766
                        }
 
767
                }
 
768
                
 
769
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
770
                        return visitor.VisitCollectionInitializerExpression(this, data);
 
771
                }
 
772
                
 
773
                public override string ToString() {
 
774
                        return string.Format("[CollectionInitializerExpression CreateExpressions={0}]", GetCollectionString(CreateExpressions));
 
775
                }
 
776
        }
 
777
        
 
778
        internal sealed class NullCollectionInitializerExpression : CollectionInitializerExpression {
 
779
                
 
780
                internal static NullCollectionInitializerExpression Instance = new NullCollectionInitializerExpression();
 
781
                
 
782
                public override bool IsNull {
 
783
                        get {
 
784
                                return true;
 
785
                        }
 
786
                }
 
787
                
 
788
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
789
                        return null;
 
790
                }
 
791
                
 
792
                public override string ToString() {
 
793
                        return "[NullCollectionInitializerExpression]";
 
794
                }
 
795
        }
 
796
        
790
797
        public class ConditionalExpression : Expression {
791
798
                
792
799
                Expression condition;
852
859
                        }
853
860
                        set {
854
861
                                constructorInitializer = value ?? ConstructorInitializer.Null;
 
862
                                if (!constructorInitializer.IsNull) constructorInitializer.Parent = this;
855
863
                        }
856
864
                }
857
865
                
865
873
                        }
866
874
                }
867
875
                
868
 
                public ConstructorDeclaration(string name, Modifiers modifier, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes) : 
869
 
                                base(modifier, attributes, name, parameters) {
 
876
                public ConstructorDeclaration(string name, Modifiers modifier, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes) {
 
877
                        Name = name;
 
878
                        Modifier = modifier;
 
879
                        Parameters = parameters;
 
880
                        Attributes = attributes;
870
881
                        constructorInitializer = ConstructorInitializer.Null;
871
882
                        body = BlockStatement.Null;
872
883
                }
873
884
                
874
 
                public ConstructorDeclaration(string name, Modifiers modifier, List<ParameterDeclarationExpression> parameters, ConstructorInitializer constructorInitializer, List<AttributeSection> attributes) : 
875
 
                                base(modifier, attributes, name, parameters) {
 
885
                public ConstructorDeclaration(string name, Modifiers modifier, List<ParameterDeclarationExpression> parameters, ConstructorInitializer constructorInitializer, List<AttributeSection> attributes) {
 
886
                        Name = name;
 
887
                        Modifier = modifier;
 
888
                        Parameters = parameters;
876
889
                        ConstructorInitializer = constructorInitializer;
 
890
                        Attributes = attributes;
877
891
                        body = BlockStatement.Null;
878
892
                }
879
893
                
936
950
                }
937
951
        }
938
952
        
939
 
        public class NullConstructorInitializer : ConstructorInitializer {
940
 
                
941
 
                private NullConstructorInitializer() {
942
 
                }
943
 
                
944
 
                static NullConstructorInitializer instance = new NullConstructorInitializer();
945
 
                
946
 
                public static NullConstructorInitializer Instance {
947
 
                        get {
948
 
                                return instance;
949
 
                        }
950
 
                }
 
953
        internal sealed class NullConstructorInitializer : ConstructorInitializer {
 
954
                
 
955
                internal static NullConstructorInitializer Instance = new NullConstructorInitializer();
951
956
                
952
957
                public override bool IsNull {
953
958
                        get {
1039
1044
                        }
1040
1045
                }
1041
1046
                
1042
 
                public DeclareDeclaration(string name, Modifiers modifier, TypeReference typeReference, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes, string library, string alias, CharsetModifier charset) : 
1043
 
                                base(modifier, attributes, name, parameters) {
 
1047
                public DeclareDeclaration(string name, Modifiers modifier, TypeReference typeReference, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes, string library, string alias, CharsetModifier charset) {
 
1048
                        Name = name;
 
1049
                        Modifier = modifier;
1044
1050
                        TypeReference = typeReference;
 
1051
                        Parameters = parameters;
 
1052
                        Attributes = attributes;
1045
1053
                        Library = library;
1046
1054
                        Alias = alias;
1047
1055
                        Charset = charset;
1129
1137
                        }
1130
1138
                }
1131
1139
                
1132
 
                public DelegateDeclaration(Modifiers modifier, List<AttributeSection> attributes) : 
1133
 
                                base(attributes) {
 
1140
                public DelegateDeclaration(Modifiers modifier, List<AttributeSection> attributes) {
1134
1141
                        Modifier = modifier;
 
1142
                        Attributes = attributes;
1135
1143
                        name = "?";
1136
1144
                        returnType = TypeReference.Null;
1137
1145
                        parameters = new List<ParameterDeclarationExpression>();
1173
1181
                        }
1174
1182
                }
1175
1183
                
1176
 
                public DestructorDeclaration(string name, Modifiers modifier, List<AttributeSection> attributes) : 
1177
 
                                base(attributes) {
 
1184
                public DestructorDeclaration(string name, Modifiers modifier, List<AttributeSection> attributes) {
1178
1185
                        Name = name;
1179
1186
                        Modifier = modifier;
 
1187
                        Attributes = attributes;
1180
1188
                        body = BlockStatement.Null;
1181
1189
                }
1182
1190
                
1415
1423
                }
1416
1424
        }
1417
1425
        
1418
 
        public class NullEventAddRegion : EventAddRegion {
 
1426
        internal sealed class NullEventAddRegion : EventAddRegion {
1419
1427
                
1420
1428
                private NullEventAddRegion() : 
1421
1429
                                base(null) {
1422
1430
                }
1423
1431
                
1424
 
                static NullEventAddRegion instance = new NullEventAddRegion();
1425
 
                
1426
 
                public static NullEventAddRegion Instance {
1427
 
                        get {
1428
 
                                return instance;
1429
 
                        }
1430
 
                }
 
1432
                internal static NullEventAddRegion Instance = new NullEventAddRegion();
1431
1433
                
1432
1434
                public override bool IsNull {
1433
1435
                        get {
1469
1471
                        }
1470
1472
                }
1471
1473
                
1472
 
                protected EventAddRemoveRegion(List<AttributeSection> attributes) : 
1473
 
                                base(attributes) {
 
1474
                protected EventAddRemoveRegion(List<AttributeSection> attributes) {
 
1475
                        Attributes = attributes;
1474
1476
                        block = BlockStatement.Null;
1475
1477
                        parameters = new List<ParameterDeclarationExpression>();
1476
1478
                }
1482
1484
                }
1483
1485
        }
1484
1486
        
1485
 
        public class EventDeclaration : ParametrizedNode {
1486
 
                
1487
 
                TypeReference typeReference;
1488
 
                
1489
 
                List<InterfaceImplementation> interfaceImplementations;
 
1487
        public class EventDeclaration : MemberNode {
1490
1488
                
1491
1489
                EventAddRegion addRegion;
1492
1490
                
1500
1498
                
1501
1499
                Expression initializer;
1502
1500
                
1503
 
                public TypeReference TypeReference {
1504
 
                        get {
1505
 
                                return typeReference;
1506
 
                        }
1507
 
                        set {
1508
 
                                typeReference = value ?? TypeReference.Null;
1509
 
                        }
1510
 
                }
1511
 
                
1512
 
                public List<InterfaceImplementation> InterfaceImplementations {
1513
 
                        get {
1514
 
                                return interfaceImplementations;
1515
 
                        }
1516
 
                        set {
1517
 
                                interfaceImplementations = value ?? new List<InterfaceImplementation>();
1518
 
                        }
1519
 
                }
1520
 
                
1521
1501
                public EventAddRegion AddRegion {
1522
1502
                        get {
1523
1503
                                return addRegion;
1573
1553
                        }
1574
1554
                }
1575
1555
                
1576
 
                public EventDeclaration(TypeReference typeReference, string name, Modifiers modifier, List<AttributeSection> attributes, List<ParameterDeclarationExpression> parameters) : 
1577
 
                                base(modifier, attributes, name, parameters) {
1578
 
                        TypeReference = typeReference;
1579
 
                        interfaceImplementations = new List<InterfaceImplementation>();
1580
 
                        addRegion = EventAddRegion.Null;
1581
 
                        removeRegion = EventRemoveRegion.Null;
1582
 
                        raiseRegion = EventRaiseRegion.Null;
1583
 
                        bodyStart = Location.Empty;
1584
 
                        bodyEnd = Location.Empty;
1585
 
                        initializer = Expression.Null;
1586
 
                }
1587
 
                
1588
 
                public EventDeclaration(TypeReference typeReference, Modifiers modifier, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes, string name, List<InterfaceImplementation> interfaceImplementations) : 
1589
 
                                base(modifier, attributes, name, parameters) {
1590
 
                        TypeReference = typeReference;
1591
 
                        InterfaceImplementations = interfaceImplementations;
 
1556
                public EventDeclaration() {
1592
1557
                        addRegion = EventAddRegion.Null;
1593
1558
                        removeRegion = EventRemoveRegion.Null;
1594
1559
                        raiseRegion = EventRaiseRegion.Null;
1603
1568
                        }
1604
1569
                }
1605
1570
                
 
1571
                public bool HasAddRegion {
 
1572
                        get {
 
1573
                                return !addRegion.IsNull;
 
1574
                        }
 
1575
                }
 
1576
                
1606
1577
                public bool HasRaiseRegion {
1607
1578
                        get {
1608
1579
                                return !raiseRegion.IsNull;
1609
1580
                        }
1610
1581
                }
1611
1582
                
1612
 
                public bool HasAddRegion {
1613
 
                        get {
1614
 
                                return !addRegion.IsNull;
1615
 
                        }
1616
 
                }
1617
 
                
1618
1583
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
1619
1584
                        return visitor.VisitEventDeclaration(this, data);
1620
1585
                }
1621
1586
                
1622
1587
                public override string ToString() {
1623
 
                        return string.Format("[EventDeclaration TypeReference={0} InterfaceImplementations={1} AddRegion={2} Re" +
1624
 
                                        "moveRegion={3} RaiseRegion={4} BodyStart={5} BodyEnd={6} Initializer={7} Name={8" +
1625
 
                                        "} Parameters={9} Attributes={10} Modifier={11}]", TypeReference, GetCollectionString(InterfaceImplementations), AddRegion, RemoveRegion, RaiseRegion, BodyStart, BodyEnd, Initializer, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
 
1588
                        return string.Format("[EventDeclaration AddRegion={0} RemoveRegion={1} RaiseRegion={2} BodyStart={3} Bo" +
 
1589
                                        "dyEnd={4} Initializer={5} InterfaceImplementations={6} TypeReference={7} Name={8" +
 
1590
                                        "} Parameters={9} Attributes={10} Modifier={11}]", AddRegion, RemoveRegion, RaiseRegion, BodyStart, BodyEnd, Initializer, GetCollectionString(InterfaceImplementations), TypeReference, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
1626
1591
                }
1627
1592
        }
1628
1593
        
1647
1612
                }
1648
1613
        }
1649
1614
        
1650
 
        public class NullEventRaiseRegion : EventRaiseRegion {
 
1615
        internal sealed class NullEventRaiseRegion : EventRaiseRegion {
1651
1616
                
1652
1617
                private NullEventRaiseRegion() : 
1653
1618
                                base(null) {
1654
1619
                }
1655
1620
                
1656
 
                static NullEventRaiseRegion instance = new NullEventRaiseRegion();
1657
 
                
1658
 
                public static NullEventRaiseRegion Instance {
1659
 
                        get {
1660
 
                                return instance;
1661
 
                        }
1662
 
                }
 
1621
                internal static NullEventRaiseRegion Instance = new NullEventRaiseRegion();
1663
1622
                
1664
1623
                public override bool IsNull {
1665
1624
                        get {
1697
1656
                }
1698
1657
        }
1699
1658
        
1700
 
        public class NullEventRemoveRegion : EventRemoveRegion {
 
1659
        internal sealed class NullEventRemoveRegion : EventRemoveRegion {
1701
1660
                
1702
1661
                private NullEventRemoveRegion() : 
1703
1662
                                base(null) {
1704
1663
                }
1705
1664
                
1706
 
                static NullEventRemoveRegion instance = new NullEventRemoveRegion();
1707
 
                
1708
 
                public static NullEventRemoveRegion Instance {
1709
 
                        get {
1710
 
                                return instance;
1711
 
                        }
1712
 
                }
 
1665
                internal static NullEventRemoveRegion Instance = new NullEventRemoveRegion();
1713
1666
                
1714
1667
                public override bool IsNull {
1715
1668
                        get {
1803
1756
                        }
1804
1757
                }
1805
1758
                
1806
 
                public FieldDeclaration(List<AttributeSection> attributes) : 
1807
 
                                base(attributes) {
 
1759
                public FieldDeclaration(List<AttributeSection> attributes) {
 
1760
                        Attributes = attributes;
1808
1761
                        typeReference = TypeReference.Null;
1809
1762
                        fields = new List<VariableDeclaration>();
1810
1763
                }
1811
1764
                
1812
 
                public FieldDeclaration(List<AttributeSection> attributes, TypeReference typeReference, Modifiers modifier) : 
1813
 
                                base(attributes) {
 
1765
                public FieldDeclaration(List<AttributeSection> attributes, TypeReference typeReference, Modifiers modifier) {
 
1766
                        Attributes = attributes;
1814
1767
                        TypeReference = typeReference;
1815
1768
                        Modifier = modifier;
1816
1769
                        fields = new List<VariableDeclaration>();
1845
1798
                }
1846
1799
        }
1847
1800
        
1848
 
        public class FieldReferenceExpression : Expression {
1849
 
                
1850
 
                Expression targetObject;
1851
 
                
1852
 
                string fieldName;
1853
 
                
1854
 
                public Expression TargetObject {
1855
 
                        get {
1856
 
                                return targetObject;
1857
 
                        }
1858
 
                        set {
1859
 
                                targetObject = value ?? Expression.Null;
1860
 
                                if (!targetObject.IsNull) targetObject.Parent = this;
1861
 
                        }
1862
 
                }
1863
 
                
1864
 
                public string FieldName {
1865
 
                        get {
1866
 
                                return fieldName;
1867
 
                        }
1868
 
                        set {
1869
 
                                fieldName = value ?? "";
1870
 
                        }
1871
 
                }
1872
 
                
1873
 
                public FieldReferenceExpression(Expression targetObject, string fieldName) {
1874
 
                        TargetObject = targetObject;
1875
 
                        FieldName = fieldName;
1876
 
                }
1877
 
                
1878
 
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
1879
 
                        return visitor.VisitFieldReferenceExpression(this, data);
1880
 
                }
1881
 
                
1882
 
                public override string ToString() {
1883
 
                        return string.Format("[FieldReferenceExpression TargetObject={0} FieldName={1}]", TargetObject, FieldName);
1884
 
                }
1885
 
        }
1886
 
        
1887
1801
        public class FixedStatement : StatementWithEmbeddedStatement {
1888
1802
                
1889
 
                TypeReference typeReference;
1890
 
                
1891
 
                List<VariableDeclaration> pointerDeclarators;
1892
 
                
1893
 
                public TypeReference TypeReference {
1894
 
                        get {
1895
 
                                return typeReference;
1896
 
                        }
1897
 
                        set {
1898
 
                                typeReference = value ?? TypeReference.Null;
1899
 
                        }
1900
 
                }
1901
 
                
1902
 
                public List<VariableDeclaration> PointerDeclarators {
1903
 
                        get {
1904
 
                                return pointerDeclarators;
1905
 
                        }
1906
 
                        set {
1907
 
                                pointerDeclarators = value ?? new List<VariableDeclaration>();
1908
 
                        }
1909
 
                }
1910
 
                
1911
 
                public FixedStatement(TypeReference typeReference, List<VariableDeclaration> pointerDeclarators, Statement embeddedStatement) {
1912
 
                        TypeReference = typeReference;
1913
 
                        PointerDeclarators = pointerDeclarators;
 
1803
                Statement pointerDeclaration;
 
1804
                
 
1805
                public Statement PointerDeclaration {
 
1806
                        get {
 
1807
                                return pointerDeclaration;
 
1808
                        }
 
1809
                        set {
 
1810
                                pointerDeclaration = value ?? Statement.Null;
 
1811
                                if (!pointerDeclaration.IsNull) pointerDeclaration.Parent = this;
 
1812
                        }
 
1813
                }
 
1814
                
 
1815
                public FixedStatement(Statement pointerDeclaration, Statement embeddedStatement) {
 
1816
                        PointerDeclaration = pointerDeclaration;
1914
1817
                        EmbeddedStatement = embeddedStatement;
1915
1818
                }
1916
1819
                
1919
1822
                }
1920
1823
                
1921
1824
                public override string ToString() {
1922
 
                        return string.Format("[FixedStatement TypeReference={0} PointerDeclarators={1} EmbeddedStatement={2}]", TypeReference, GetCollectionString(PointerDeclarators), EmbeddedStatement);
 
1825
                        return string.Format("[FixedStatement PointerDeclaration={0} EmbeddedStatement={1}]", PointerDeclaration, EmbeddedStatement);
1923
1826
                }
1924
1827
        }
1925
1828
        
2203
2106
                
2204
2107
                string identifier;
2205
2108
                
 
2109
                List<TypeReference> typeArguments;
 
2110
                
2206
2111
                public string Identifier {
2207
2112
                        get {
2208
2113
                                return identifier;
2212
2117
                        }
2213
2118
                }
2214
2119
                
 
2120
                public List<TypeReference> TypeArguments {
 
2121
                        get {
 
2122
                                return typeArguments;
 
2123
                        }
 
2124
                        set {
 
2125
                                typeArguments = value ?? new List<TypeReference>();
 
2126
                        }
 
2127
                }
 
2128
                
2215
2129
                public IdentifierExpression(string identifier) {
2216
2130
                        Identifier = identifier;
 
2131
                        typeArguments = new List<TypeReference>();
2217
2132
                }
2218
2133
                
2219
2134
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
2221
2136
                }
2222
2137
                
2223
2138
                public override string ToString() {
2224
 
                        return string.Format("[IdentifierExpression Identifier={0}]", Identifier);
 
2139
                        return string.Format("[IdentifierExpression Identifier={0} TypeArguments={1}]", Identifier, GetCollectionString(TypeArguments));
2225
2140
                }
2226
2141
        }
2227
2142
        
2279
2194
                        elseIfSections = new List<ElseIfSection>();
2280
2195
                }
2281
2196
                
 
2197
                public bool HasElseIfSections {
 
2198
                        get {
 
2199
                                return elseIfSections.Count > 0;
 
2200
                        }
 
2201
                }
 
2202
                
 
2203
                public bool HasElseStatements {
 
2204
                        get {
 
2205
                                return falseStatement.Count > 0;
 
2206
                        }
 
2207
                }
 
2208
                
2282
2209
 
2283
2210
                        public IfElseStatement(Expression condition, Statement trueStatement)
2284
2211
                                : this(condition) {
2292
2219
                                this.falseStatement.Add(Statement.CheckNull(falseStatement));
2293
2220
                        }
2294
2221
                
2295
 
                public bool HasElseStatements {
2296
 
                        get {
2297
 
                                return falseStatement.Count > 0;
2298
 
                        }
2299
 
                }
2300
 
                
2301
 
                public bool HasElseIfSections {
2302
 
                        get {
2303
 
                                return elseIfSections.Count > 0;
2304
 
                        }
2305
 
                }
2306
 
                
2307
2222
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
2308
2223
                        return visitor.VisitIfElseStatement(this, data);
2309
2224
                }
2393
2308
                        }
2394
2309
                }
2395
2310
                
2396
 
                public IndexerDeclaration(Modifiers modifier, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes) : 
2397
 
                                base(attributes) {
 
2311
                public IndexerDeclaration(Modifiers modifier, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes) {
2398
2312
                        Modifier = modifier;
2399
2313
                        Parameters = parameters;
 
2314
                        Attributes = attributes;
2400
2315
                        interfaceImplementations = new List<InterfaceImplementation>();
2401
2316
                        typeReference = TypeReference.Null;
2402
2317
                        bodyStart = Location.Empty;
2405
2320
                        setRegion = PropertySetRegion.Null;
2406
2321
                }
2407
2322
                
2408
 
                public IndexerDeclaration(TypeReference typeReference, List<ParameterDeclarationExpression> parameters, Modifiers modifier, List<AttributeSection> attributes) : 
2409
 
                                base(attributes) {
 
2323
                public IndexerDeclaration(TypeReference typeReference, List<ParameterDeclarationExpression> parameters, Modifiers modifier, List<AttributeSection> attributes) {
2410
2324
                        TypeReference = typeReference;
2411
2325
                        Parameters = parameters;
2412
2326
                        Modifier = modifier;
 
2327
                        Attributes = attributes;
2413
2328
                        interfaceImplementations = new List<InterfaceImplementation>();
2414
2329
                        bodyStart = Location.Empty;
2415
2330
                        bodyEnd = Location.Empty;
2417
2332
                        setRegion = PropertySetRegion.Null;
2418
2333
                }
2419
2334
                
 
2335
                public bool IsWriteOnly {
 
2336
                        get {
 
2337
                                return !HasGetRegion && HasSetRegion;
 
2338
                        }
 
2339
                }
 
2340
                
2420
2341
                public bool HasSetRegion {
2421
2342
                        get {
2422
2343
                                return !setRegion.IsNull;
2423
2344
                        }
2424
2345
                }
2425
2346
                
 
2347
                public bool HasGetRegion {
 
2348
                        get {
 
2349
                                return !getRegion.IsNull;
 
2350
                        }
 
2351
                }
 
2352
                
2426
2353
                public bool IsReadOnly {
2427
2354
                        get {
2428
2355
                                return HasGetRegion && !HasSetRegion;
2429
2356
                        }
2430
2357
                }
2431
2358
                
2432
 
                public bool IsWriteOnly {
2433
 
                        get {
2434
 
                                return !HasGetRegion && HasSetRegion;
2435
 
                        }
2436
 
                }
2437
 
                
2438
 
                public bool HasGetRegion {
2439
 
                        get {
2440
 
                                return !getRegion.IsNull;
2441
 
                        }
2442
 
                }
2443
 
                
2444
2359
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
2445
2360
                        return visitor.VisitIndexerDeclaration(this, data);
2446
2361
                }
2535
2450
                
2536
2451
                List<Expression> arguments;
2537
2452
                
2538
 
                List<TypeReference> typeArguments;
2539
 
                
2540
2453
                public Expression TargetObject {
2541
2454
                        get {
2542
2455
                                return targetObject;
2556
2469
                        }
2557
2470
                }
2558
2471
                
2559
 
                public List<TypeReference> TypeArguments {
2560
 
                        get {
2561
 
                                return typeArguments;
2562
 
                        }
2563
 
                        set {
2564
 
                                typeArguments = value ?? new List<TypeReference>();
2565
 
                        }
2566
 
                }
2567
 
                
2568
2472
                public InvocationExpression(Expression targetObject) {
2569
2473
                        TargetObject = targetObject;
2570
2474
                        arguments = new List<Expression>();
2571
 
                        typeArguments = new List<TypeReference>();
2572
2475
                }
2573
2476
                
2574
2477
                public InvocationExpression(Expression targetObject, List<Expression> arguments) {
2575
2478
                        TargetObject = targetObject;
2576
2479
                        Arguments = arguments;
2577
 
                        typeArguments = new List<TypeReference>();
2578
 
                }
2579
 
                
2580
 
                public InvocationExpression(Expression targetObject, List<Expression> arguments, List<TypeReference> typeArguments) {
2581
 
                        TargetObject = targetObject;
2582
 
                        Arguments = arguments;
2583
 
                        TypeArguments = typeArguments;
2584
2480
                }
2585
2481
                
2586
2482
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
2588
2484
                }
2589
2485
                
2590
2486
                public override string ToString() {
2591
 
                        return string.Format("[InvocationExpression TargetObject={0} Arguments={1} TypeArguments={2}]", TargetObject, GetCollectionString(Arguments), GetCollectionString(TypeArguments));
 
2487
                        return string.Format("[InvocationExpression TargetObject={0} Arguments={1}]", TargetObject, GetCollectionString(Arguments));
2592
2488
                }
2593
2489
        }
2594
2490
        
2618
2514
                }
2619
2515
        }
2620
2516
        
 
2517
        public class LambdaExpression : Expression {
 
2518
                
 
2519
                List<ParameterDeclarationExpression> parameters;
 
2520
                
 
2521
                BlockStatement statementBody;
 
2522
                
 
2523
                Expression expressionBody;
 
2524
                
 
2525
                public List<ParameterDeclarationExpression> Parameters {
 
2526
                        get {
 
2527
                                return parameters;
 
2528
                        }
 
2529
                        set {
 
2530
                                parameters = value ?? new List<ParameterDeclarationExpression>();
 
2531
                        }
 
2532
                }
 
2533
                
 
2534
                public BlockStatement StatementBody {
 
2535
                        get {
 
2536
                                return statementBody;
 
2537
                        }
 
2538
                        set {
 
2539
                                statementBody = value ?? BlockStatement.Null;
 
2540
                                if (!statementBody.IsNull) statementBody.Parent = this;
 
2541
                        }
 
2542
                }
 
2543
                
 
2544
                public Expression ExpressionBody {
 
2545
                        get {
 
2546
                                return expressionBody;
 
2547
                        }
 
2548
                        set {
 
2549
                                expressionBody = value ?? Expression.Null;
 
2550
                                if (!expressionBody.IsNull) expressionBody.Parent = this;
 
2551
                        }
 
2552
                }
 
2553
                
 
2554
                public LambdaExpression() {
 
2555
                        parameters = new List<ParameterDeclarationExpression>();
 
2556
                        statementBody = BlockStatement.Null;
 
2557
                        expressionBody = Expression.Null;
 
2558
                }
 
2559
                
 
2560
public Location ExtendedEndLocation { get; set; }
 
2561
                
 
2562
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
2563
                        return visitor.VisitLambdaExpression(this, data);
 
2564
                }
 
2565
                
 
2566
                public override string ToString() {
 
2567
                        return string.Format("[LambdaExpression Parameters={0} StatementBody={1} ExpressionBody={2}]", GetCollectionString(Parameters), StatementBody, ExpressionBody);
 
2568
                }
 
2569
        }
 
2570
        
2621
2571
        public class LockStatement : StatementWithEmbeddedStatement {
2622
2572
                
2623
2573
                Expression lockExpression;
2646
2596
                }
2647
2597
        }
2648
2598
        
2649
 
        public class MethodDeclaration : ParametrizedNode {
 
2599
        public abstract class MemberNode : ParametrizedNode {
 
2600
                
 
2601
                List<InterfaceImplementation> interfaceImplementations;
2650
2602
                
2651
2603
                TypeReference typeReference;
2652
2604
                
 
2605
                public List<InterfaceImplementation> InterfaceImplementations {
 
2606
                        get {
 
2607
                                return interfaceImplementations;
 
2608
                        }
 
2609
                        set {
 
2610
                                interfaceImplementations = value ?? new List<InterfaceImplementation>();
 
2611
                        }
 
2612
                }
 
2613
                
 
2614
                public TypeReference TypeReference {
 
2615
                        get {
 
2616
                                return typeReference;
 
2617
                        }
 
2618
                        set {
 
2619
                                typeReference = value ?? TypeReference.Null;
 
2620
                        }
 
2621
                }
 
2622
                
 
2623
                protected MemberNode() {
 
2624
                        interfaceImplementations = new List<InterfaceImplementation>();
 
2625
                        typeReference = TypeReference.Null;
 
2626
                }
 
2627
                
 
2628
                protected MemberNode(Modifiers modifier, List<AttributeSection> attributes, string name, List<ParameterDeclarationExpression> parameters) {
 
2629
                        Modifier = modifier;
 
2630
                        Attributes = attributes;
 
2631
                        Name = name;
 
2632
                        Parameters = parameters;
 
2633
                        interfaceImplementations = new List<InterfaceImplementation>();
 
2634
                        typeReference = TypeReference.Null;
 
2635
                }
 
2636
        }
 
2637
        
 
2638
        public class MemberReferenceExpression : Expression {
 
2639
                
 
2640
                Expression targetObject;
 
2641
                
 
2642
                string memberName;
 
2643
                
 
2644
                List<TypeReference> typeArguments;
 
2645
                
 
2646
                public Expression TargetObject {
 
2647
                        get {
 
2648
                                return targetObject;
 
2649
                        }
 
2650
                        set {
 
2651
                                targetObject = value ?? Expression.Null;
 
2652
                                if (!targetObject.IsNull) targetObject.Parent = this;
 
2653
                        }
 
2654
                }
 
2655
                
 
2656
                public string MemberName {
 
2657
                        get {
 
2658
                                return memberName;
 
2659
                        }
 
2660
                        set {
 
2661
                                memberName = value ?? "";
 
2662
                        }
 
2663
                }
 
2664
                
 
2665
                public List<TypeReference> TypeArguments {
 
2666
                        get {
 
2667
                                return typeArguments;
 
2668
                        }
 
2669
                        set {
 
2670
                                typeArguments = value ?? new List<TypeReference>();
 
2671
                        }
 
2672
                }
 
2673
                
 
2674
                public MemberReferenceExpression(Expression targetObject, string memberName) {
 
2675
                        TargetObject = targetObject;
 
2676
                        MemberName = memberName;
 
2677
                        typeArguments = new List<TypeReference>();
 
2678
                }
 
2679
                
 
2680
[Obsolete] public string FieldName { get { return MemberName; } set { MemberName = value; } }
 
2681
                
 
2682
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
2683
                        return visitor.VisitMemberReferenceExpression(this, data);
 
2684
                }
 
2685
                
 
2686
                public override string ToString() {
 
2687
                        return string.Format("[MemberReferenceExpression TargetObject={0} MemberName={1} TypeArguments={2}]", TargetObject, MemberName, GetCollectionString(TypeArguments));
 
2688
                }
 
2689
        }
 
2690
        
 
2691
        public class MethodDeclaration : MemberNode {
 
2692
                
2653
2693
                BlockStatement body;
2654
2694
                
2655
2695
                List<string> handlesClause;
2656
2696
                
2657
 
                List<InterfaceImplementation> interfaceImplementations;
2658
 
                
2659
2697
                List<TemplateDefinition> templates;
2660
2698
                
2661
 
                public TypeReference TypeReference {
2662
 
                        get {
2663
 
                                return typeReference;
2664
 
                        }
2665
 
                        set {
2666
 
                                typeReference = value ?? TypeReference.Null;
2667
 
                        }
2668
 
                }
 
2699
                bool isExtensionMethod;
2669
2700
                
2670
2701
                public BlockStatement Body {
2671
2702
                        get {
2686
2717
                        }
2687
2718
                }
2688
2719
                
2689
 
                public List<InterfaceImplementation> InterfaceImplementations {
2690
 
                        get {
2691
 
                                return interfaceImplementations;
2692
 
                        }
2693
 
                        set {
2694
 
                                interfaceImplementations = value ?? new List<InterfaceImplementation>();
2695
 
                        }
2696
 
                }
2697
 
                
2698
2720
                public List<TemplateDefinition> Templates {
2699
2721
                        get {
2700
2722
                                return templates;
2704
2726
                        }
2705
2727
                }
2706
2728
                
2707
 
                public MethodDeclaration(string name, Modifiers modifier, TypeReference typeReference, List<ParameterDeclarationExpression> parameters, List<AttributeSection> attributes) : 
2708
 
                                base(modifier, attributes, name, parameters) {
2709
 
                        TypeReference = typeReference;
 
2729
                public bool IsExtensionMethod {
 
2730
                        get {
 
2731
                                return isExtensionMethod;
 
2732
                        }
 
2733
                        set {
 
2734
                                isExtensionMethod = value;
 
2735
                        }
 
2736
                }
 
2737
                
 
2738
                public MethodDeclaration() {
2710
2739
                        body = BlockStatement.Null;
2711
2740
                        handlesClause = new List<String>();
2712
 
                        interfaceImplementations = new List<InterfaceImplementation>();
2713
2741
                        templates = new List<TemplateDefinition>();
2714
2742
                }
2715
2743
                
2718
2746
                }
2719
2747
                
2720
2748
                public override string ToString() {
2721
 
                        return string.Format("[MethodDeclaration TypeReference={0} Body={1} HandlesClause={2} InterfaceImplemen" +
2722
 
                                        "tations={3} Templates={4} Name={5} Parameters={6} Attributes={7} Modifier={8}]", TypeReference, Body, GetCollectionString(HandlesClause), GetCollectionString(InterfaceImplementations), GetCollectionString(Templates), Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
 
2749
                        return string.Format("[MethodDeclaration Body={0} HandlesClause={1} Templates={2} IsExtensionMethod={3}" +
 
2750
                                        " InterfaceImplementations={4} TypeReference={5} Name={6} Parameters={7} Attribut" +
 
2751
                                        "es={8} Modifier={9}]", Body, GetCollectionString(HandlesClause), GetCollectionString(Templates), IsExtensionMethod, GetCollectionString(InterfaceImplementations), TypeReference, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
2723
2752
                }
2724
2753
        }
2725
2754
        
2794
2823
                
2795
2824
                List<Expression> parameters;
2796
2825
                
 
2826
                CollectionInitializerExpression objectInitializer;
 
2827
                
2797
2828
                public TypeReference CreateType {
2798
2829
                        get {
2799
2830
                                return createType;
2812
2843
                        }
2813
2844
                }
2814
2845
                
 
2846
                public CollectionInitializerExpression ObjectInitializer {
 
2847
                        get {
 
2848
                                return objectInitializer;
 
2849
                        }
 
2850
                        set {
 
2851
                                objectInitializer = value ?? CollectionInitializerExpression.Null;
 
2852
                                if (!objectInitializer.IsNull) objectInitializer.Parent = this;
 
2853
                        }
 
2854
                }
 
2855
                
2815
2856
                public ObjectCreateExpression(TypeReference createType, List<Expression> parameters) {
2816
2857
                        CreateType = createType;
2817
2858
                        Parameters = parameters;
 
2859
                        objectInitializer = CollectionInitializerExpression.Null;
 
2860
                }
 
2861
                
 
2862
                public bool IsAnonymousType {
 
2863
                        get {
 
2864
                                return createType.IsNull || string.IsNullOrEmpty(createType.Type);
 
2865
                        }
2818
2866
                }
2819
2867
                
2820
2868
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
2822
2870
                }
2823
2871
                
2824
2872
                public override string ToString() {
2825
 
                        return string.Format("[ObjectCreateExpression CreateType={0} Parameters={1}]", CreateType, GetCollectionString(Parameters));
 
2873
                        return string.Format("[ObjectCreateExpression CreateType={0} Parameters={1} ObjectInitializer={2}]", CreateType, GetCollectionString(Parameters), ObjectInitializer);
2826
2874
                }
2827
2875
        }
2828
2876
        
2876
2924
                        }
2877
2925
                }
2878
2926
                
2879
 
                public OperatorDeclaration(Modifiers modifier, List<AttributeSection> attributes, List<ParameterDeclarationExpression> parameters, TypeReference typeReference, ConversionType conversionType) : 
2880
 
                                base(null, modifier, typeReference, parameters, attributes) {
2881
 
                        ConversionType = conversionType;
2882
 
                        returnTypeAttributes = new List<AttributeSection>();
2883
 
                }
2884
 
                
2885
 
                public OperatorDeclaration(Modifiers modifier, List<AttributeSection> attributes, List<ParameterDeclarationExpression> parameters, TypeReference typeReference, OverloadableOperatorType overloadableOperator) : 
2886
 
                                base(null, modifier, typeReference, parameters, attributes) {
2887
 
                        OverloadableOperator = overloadableOperator;
 
2927
                public OperatorDeclaration() {
2888
2928
                        returnTypeAttributes = new List<AttributeSection>();
2889
2929
                }
2890
2930
                
2900
2940
                
2901
2941
                public override string ToString() {
2902
2942
                        return string.Format("[OperatorDeclaration ConversionType={0} ReturnTypeAttributes={1} OverloadableOper" +
2903
 
                                        "ator={2} TypeReference={3} Body={4} HandlesClause={5} InterfaceImplementations={" +
2904
 
                                        "6} Templates={7} Name={8} Parameters={9} Attributes={10} Modifier={11}]", ConversionType, GetCollectionString(ReturnTypeAttributes), OverloadableOperator, TypeReference, Body, GetCollectionString(HandlesClause), GetCollectionString(InterfaceImplementations), GetCollectionString(Templates), Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
 
2943
                                        "ator={2} Body={3} HandlesClause={4} Templates={5} IsExtensionMethod={6} Interfac" +
 
2944
                                        "eImplementations={7} TypeReference={8} Name={9} Parameters={10} Attributes={11} " +
 
2945
                                        "Modifier={12}]", ConversionType, GetCollectionString(ReturnTypeAttributes), OverloadableOperator, Body, GetCollectionString(HandlesClause), GetCollectionString(Templates), IsExtensionMethod, GetCollectionString(InterfaceImplementations), TypeReference, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
2905
2946
                }
2906
2947
        }
2907
2948
        
3058
3099
                        }
3059
3100
                }
3060
3101
                
3061
 
                protected ParametrizedNode(Modifiers modifier, List<AttributeSection> attributes, string name, List<ParameterDeclarationExpression> parameters) : 
3062
 
                                base(attributes) {
 
3102
                protected ParametrizedNode() {
 
3103
                        name = "";
 
3104
                        parameters = new List<ParameterDeclarationExpression>();
 
3105
                }
 
3106
                
 
3107
                protected ParametrizedNode(Modifiers modifier, List<AttributeSection> attributes, string name, List<ParameterDeclarationExpression> parameters) {
3063
3108
                        Modifier = modifier;
 
3109
                        Attributes = attributes;
3064
3110
                        Name = name;
3065
3111
                        Parameters = parameters;
3066
3112
                }
3067
 
                
3068
 
                protected ParametrizedNode(Modifiers modifier, List<AttributeSection> attributes) : 
3069
 
                                base(attributes) {
3070
 
                        Modifier = modifier;
3071
 
                        name = "";
3072
 
                        parameters = new List<ParameterDeclarationExpression>();
3073
 
                }
3074
3113
        }
3075
3114
        
3076
3115
        public class ParenthesizedExpression : Expression {
3106
3145
                
3107
3146
                string identifier;
3108
3147
                
 
3148
                List<TypeReference> typeArguments;
 
3149
                
3109
3150
                public Expression TargetObject {
3110
3151
                        get {
3111
3152
                                return targetObject;
3125
3166
                        }
3126
3167
                }
3127
3168
                
 
3169
                public List<TypeReference> TypeArguments {
 
3170
                        get {
 
3171
                                return typeArguments;
 
3172
                        }
 
3173
                        set {
 
3174
                                typeArguments = value ?? new List<TypeReference>();
 
3175
                        }
 
3176
                }
 
3177
                
3128
3178
                public PointerReferenceExpression(Expression targetObject, string identifier) {
3129
3179
                        TargetObject = targetObject;
3130
3180
                        Identifier = identifier;
 
3181
                        typeArguments = new List<TypeReference>();
3131
3182
                }
3132
3183
                
3133
3184
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
3135
3186
                }
3136
3187
                
3137
3188
                public override string ToString() {
3138
 
                        return string.Format("[PointerReferenceExpression TargetObject={0} Identifier={1}]", TargetObject, Identifier);
 
3189
                        return string.Format("[PointerReferenceExpression TargetObject={0} Identifier={1} TypeArguments={2}]", TargetObject, Identifier, GetCollectionString(TypeArguments));
3139
3190
                }
3140
3191
        }
3141
3192
        
3142
 
        public class PropertyDeclaration : ParametrizedNode {
3143
 
                
3144
 
                List<InterfaceImplementation> interfaceImplementations;
3145
 
                
3146
 
                TypeReference typeReference;
 
3193
        public class PropertyDeclaration : MemberNode {
3147
3194
                
3148
3195
                Location bodyStart;
3149
3196
                
3153
3200
                
3154
3201
                PropertySetRegion setRegion;
3155
3202
                
3156
 
                public List<InterfaceImplementation> InterfaceImplementations {
3157
 
                        get {
3158
 
                                return interfaceImplementations;
3159
 
                        }
3160
 
                        set {
3161
 
                                interfaceImplementations = value ?? new List<InterfaceImplementation>();
3162
 
                        }
3163
 
                }
3164
 
                
3165
 
                public TypeReference TypeReference {
3166
 
                        get {
3167
 
                                return typeReference;
3168
 
                        }
3169
 
                        set {
3170
 
                                typeReference = value ?? TypeReference.Null;
3171
 
                        }
3172
 
                }
3173
 
                
3174
3203
                public Location BodyStart {
3175
3204
                        get {
3176
3205
                                return bodyStart;
3207
3236
                        }
3208
3237
                }
3209
3238
                
3210
 
                public PropertyDeclaration(Modifiers modifier, List<AttributeSection> attributes, string name, List<ParameterDeclarationExpression> parameters) : 
3211
 
                                base(modifier, attributes, name, parameters) {
3212
 
                        interfaceImplementations = new List<InterfaceImplementation>();
3213
 
                        typeReference = TypeReference.Null;
 
3239
                public PropertyDeclaration(Modifiers modifier, List<AttributeSection> attributes, string name, List<ParameterDeclarationExpression> parameters) {
 
3240
                        Modifier = modifier;
 
3241
                        Attributes = attributes;
 
3242
                        Name = name;
 
3243
                        Parameters = parameters;
3214
3244
                        bodyStart = Location.Empty;
3215
3245
                        bodyEnd = Location.Empty;
3216
3246
                        getRegion = PropertyGetRegion.Null;
3229
3259
                        }
3230
3260
                }
3231
3261
                
 
3262
                public bool HasSetRegion {
 
3263
                        get {
 
3264
                                return !setRegion.IsNull;
 
3265
                        }
 
3266
                }
 
3267
                
 
3268
                public bool IsReadOnly {
 
3269
                        get {
 
3270
                                return HasGetRegion && !HasSetRegion;
 
3271
                        }
 
3272
                }
 
3273
                
3232
3274
 
3233
3275
                internal PropertyDeclaration(string name, TypeReference typeReference, Modifiers modifier, List<AttributeSection> attributes) : this(modifier, attributes, name, null)
3234
3276
                {
3241
3283
                        }
3242
3284
                }
3243
3285
                
3244
 
                public bool HasSetRegion {
3245
 
                        get {
3246
 
                                return !setRegion.IsNull;
3247
 
                        }
3248
 
                }
3249
 
                
3250
 
                public bool IsReadOnly {
3251
 
                        get {
3252
 
                                return HasGetRegion && !HasSetRegion;
3253
 
                        }
3254
 
                }
3255
 
                
3256
3286
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
3257
3287
                        return visitor.VisitPropertyDeclaration(this, data);
3258
3288
                }
3259
3289
                
3260
3290
                public override string ToString() {
3261
 
                        return string.Format("[PropertyDeclaration InterfaceImplementations={0} TypeReference={1} BodyStart={2}" +
3262
 
                                        " BodyEnd={3} GetRegion={4} SetRegion={5} Name={6} Parameters={7} Attributes={8} " +
3263
 
                                        "Modifier={9}]", GetCollectionString(InterfaceImplementations), TypeReference, BodyStart, BodyEnd, GetRegion, SetRegion, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
 
3291
                        return string.Format("[PropertyDeclaration BodyStart={0} BodyEnd={1} GetRegion={2} SetRegion={3} Interf" +
 
3292
                                        "aceImplementations={4} TypeReference={5} Name={6} Parameters={7} Attributes={8} " +
 
3293
                                        "Modifier={9}]", BodyStart, BodyEnd, GetRegion, SetRegion, GetCollectionString(InterfaceImplementations), TypeReference, Name, GetCollectionString(Parameters), GetCollectionString(Attributes), Modifier);
3264
3294
                }
3265
3295
        }
3266
3296
        
3285
3315
                }
3286
3316
        }
3287
3317
        
3288
 
        public class NullPropertyGetRegion : PropertyGetRegion {
 
3318
        internal sealed class NullPropertyGetRegion : PropertyGetRegion {
3289
3319
                
3290
3320
                private NullPropertyGetRegion() : 
3291
3321
                                base(null, null) {
3292
3322
                }
3293
3323
                
3294
 
                static NullPropertyGetRegion instance = new NullPropertyGetRegion();
3295
 
                
3296
 
                public static NullPropertyGetRegion Instance {
3297
 
                        get {
3298
 
                                return instance;
3299
 
                        }
3300
 
                }
 
3324
                internal static NullPropertyGetRegion Instance = new NullPropertyGetRegion();
3301
3325
                
3302
3326
                public override bool IsNull {
3303
3327
                        get {
3328
3352
                        }
3329
3353
                }
3330
3354
                
3331
 
                protected PropertyGetSetRegion(BlockStatement block, List<AttributeSection> attributes) : 
3332
 
                                base(attributes) {
 
3355
                protected PropertyGetSetRegion(BlockStatement block, List<AttributeSection> attributes) {
3333
3356
                        Block = block;
 
3357
                        Attributes = attributes;
3334
3358
                }
3335
3359
                
3336
3360
                public virtual bool IsNull {
3373
3397
                }
3374
3398
        }
3375
3399
        
3376
 
        public class NullPropertySetRegion : PropertySetRegion {
 
3400
        internal sealed class NullPropertySetRegion : PropertySetRegion {
3377
3401
                
3378
3402
                private NullPropertySetRegion() : 
3379
3403
                                base(null, null) {
3380
3404
                }
3381
3405
                
3382
 
                static NullPropertySetRegion instance = new NullPropertySetRegion();
3383
 
                
3384
 
                public static NullPropertySetRegion Instance {
3385
 
                        get {
3386
 
                                return instance;
3387
 
                        }
3388
 
                }
 
3406
                internal static NullPropertySetRegion Instance = new NullPropertySetRegion();
3389
3407
                
3390
3408
                public override bool IsNull {
3391
3409
                        get {
3402
3420
                }
3403
3421
        }
3404
3422
        
 
3423
        public class QueryExpression : Expression {
 
3424
                
 
3425
                QueryExpressionFromClause fromClause;
 
3426
                
 
3427
                List<QueryExpressionClause> middleClauses;
 
3428
                
 
3429
                QueryExpressionClause selectOrGroupClause;
 
3430
                
 
3431
                QueryExpressionIntoClause intoClause;
 
3432
                
 
3433
                public QueryExpressionFromClause FromClause {
 
3434
                        get {
 
3435
                                return fromClause;
 
3436
                        }
 
3437
                        set {
 
3438
                                fromClause = value ?? QueryExpressionFromClause.Null;
 
3439
                                if (!fromClause.IsNull) fromClause.Parent = this;
 
3440
                        }
 
3441
                }
 
3442
                
 
3443
                public List<QueryExpressionClause> MiddleClauses {
 
3444
                        get {
 
3445
                                return middleClauses;
 
3446
                        }
 
3447
                        set {
 
3448
                                middleClauses = value ?? new List<QueryExpressionClause>();
 
3449
                        }
 
3450
                }
 
3451
                
 
3452
                public QueryExpressionClause SelectOrGroupClause {
 
3453
                        get {
 
3454
                                return selectOrGroupClause;
 
3455
                        }
 
3456
                        set {
 
3457
                                selectOrGroupClause = value ?? QueryExpressionClause.Null;
 
3458
                                if (!selectOrGroupClause.IsNull) selectOrGroupClause.Parent = this;
 
3459
                        }
 
3460
                }
 
3461
                
 
3462
                public QueryExpressionIntoClause IntoClause {
 
3463
                        get {
 
3464
                                return intoClause;
 
3465
                        }
 
3466
                        set {
 
3467
                                intoClause = value ?? QueryExpressionIntoClause.Null;
 
3468
                                if (!intoClause.IsNull) intoClause.Parent = this;
 
3469
                        }
 
3470
                }
 
3471
                
 
3472
                public QueryExpression() {
 
3473
                        fromClause = QueryExpressionFromClause.Null;
 
3474
                        middleClauses = new List<QueryExpressionClause>();
 
3475
                        selectOrGroupClause = QueryExpressionClause.Null;
 
3476
                        intoClause = QueryExpressionIntoClause.Null;
 
3477
                }
 
3478
                
 
3479
                public new static QueryExpression Null {
 
3480
                        get {
 
3481
                                return NullQueryExpression.Instance;
 
3482
                        }
 
3483
                }
 
3484
                
 
3485
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3486
                        return visitor.VisitQueryExpression(this, data);
 
3487
                }
 
3488
                
 
3489
                public override string ToString() {
 
3490
                        return string.Format("[QueryExpression FromClause={0} MiddleClauses={1} SelectOrGroupClause={2} IntoCla" +
 
3491
                                        "use={3}]", FromClause, GetCollectionString(MiddleClauses), SelectOrGroupClause, IntoClause);
 
3492
                }
 
3493
        }
 
3494
        
 
3495
        internal sealed class NullQueryExpression : QueryExpression {
 
3496
                
 
3497
                internal static NullQueryExpression Instance = new NullQueryExpression();
 
3498
                
 
3499
                public override bool IsNull {
 
3500
                        get {
 
3501
                                return true;
 
3502
                        }
 
3503
                }
 
3504
                
 
3505
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3506
                        return null;
 
3507
                }
 
3508
                
 
3509
                public override string ToString() {
 
3510
                        return "[NullQueryExpression]";
 
3511
                }
 
3512
        }
 
3513
        
 
3514
        public abstract class QueryExpressionClause : AbstractNode, INullable {
 
3515
                
 
3516
                public virtual bool IsNull {
 
3517
                        get {
 
3518
                                return false;
 
3519
                        }
 
3520
                }
 
3521
                
 
3522
                public static QueryExpressionClause Null {
 
3523
                        get {
 
3524
                                return NullQueryExpressionClause.Instance;
 
3525
                        }
 
3526
                }
 
3527
        }
 
3528
        
 
3529
        internal sealed class NullQueryExpressionClause : QueryExpressionClause {
 
3530
                
 
3531
                internal static NullQueryExpressionClause Instance = new NullQueryExpressionClause();
 
3532
                
 
3533
                public override bool IsNull {
 
3534
                        get {
 
3535
                                return true;
 
3536
                        }
 
3537
                }
 
3538
                
 
3539
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3540
                        return null;
 
3541
                }
 
3542
                
 
3543
                public override string ToString() {
 
3544
                        return "[NullQueryExpressionClause]";
 
3545
                }
 
3546
        }
 
3547
        
 
3548
        public class QueryExpressionFromClause : QueryExpressionFromOrJoinClause {
 
3549
                
 
3550
                public QueryExpressionFromClause() {
 
3551
                }
 
3552
                
 
3553
                public new static QueryExpressionFromClause Null {
 
3554
                        get {
 
3555
                                return NullQueryExpressionFromClause.Instance;
 
3556
                        }
 
3557
                }
 
3558
                
 
3559
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3560
                        return visitor.VisitQueryExpressionFromClause(this, data);
 
3561
                }
 
3562
                
 
3563
                public override string ToString() {
 
3564
                        return string.Format("[QueryExpressionFromClause Type={0} Identifier={1} InExpression={2}]", Type, Identifier, InExpression);
 
3565
                }
 
3566
        }
 
3567
        
 
3568
        internal sealed class NullQueryExpressionFromClause : QueryExpressionFromClause {
 
3569
                
 
3570
                internal static NullQueryExpressionFromClause Instance = new NullQueryExpressionFromClause();
 
3571
                
 
3572
                public override bool IsNull {
 
3573
                        get {
 
3574
                                return true;
 
3575
                        }
 
3576
                }
 
3577
                
 
3578
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3579
                        return null;
 
3580
                }
 
3581
                
 
3582
                public override string ToString() {
 
3583
                        return "[NullQueryExpressionFromClause]";
 
3584
                }
 
3585
        }
 
3586
        
 
3587
        public abstract class QueryExpressionFromOrJoinClause : QueryExpressionClause {
 
3588
                
 
3589
                TypeReference type;
 
3590
                
 
3591
                string identifier;
 
3592
                
 
3593
                Expression inExpression;
 
3594
                
 
3595
                public TypeReference Type {
 
3596
                        get {
 
3597
                                return type;
 
3598
                        }
 
3599
                        set {
 
3600
                                type = value ?? TypeReference.Null;
 
3601
                        }
 
3602
                }
 
3603
                
 
3604
                public string Identifier {
 
3605
                        get {
 
3606
                                return identifier;
 
3607
                        }
 
3608
                        set {
 
3609
                                identifier = string.IsNullOrEmpty(value) ? "?" : value;
 
3610
                        }
 
3611
                }
 
3612
                
 
3613
                public Expression InExpression {
 
3614
                        get {
 
3615
                                return inExpression;
 
3616
                        }
 
3617
                        set {
 
3618
                                inExpression = value ?? Expression.Null;
 
3619
                                if (!inExpression.IsNull) inExpression.Parent = this;
 
3620
                        }
 
3621
                }
 
3622
        }
 
3623
        
 
3624
        public class QueryExpressionGroupClause : QueryExpressionClause {
 
3625
                
 
3626
                Expression projection;
 
3627
                
 
3628
                Expression groupBy;
 
3629
                
 
3630
                public Expression Projection {
 
3631
                        get {
 
3632
                                return projection;
 
3633
                        }
 
3634
                        set {
 
3635
                                projection = value ?? Expression.Null;
 
3636
                                if (!projection.IsNull) projection.Parent = this;
 
3637
                        }
 
3638
                }
 
3639
                
 
3640
                public Expression GroupBy {
 
3641
                        get {
 
3642
                                return groupBy;
 
3643
                        }
 
3644
                        set {
 
3645
                                groupBy = value ?? Expression.Null;
 
3646
                                if (!groupBy.IsNull) groupBy.Parent = this;
 
3647
                        }
 
3648
                }
 
3649
                
 
3650
                public QueryExpressionGroupClause() {
 
3651
                        projection = Expression.Null;
 
3652
                        groupBy = Expression.Null;
 
3653
                }
 
3654
                
 
3655
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3656
                        return visitor.VisitQueryExpressionGroupClause(this, data);
 
3657
                }
 
3658
                
 
3659
                public override string ToString() {
 
3660
                        return string.Format("[QueryExpressionGroupClause Projection={0} GroupBy={1}]", Projection, GroupBy);
 
3661
                }
 
3662
        }
 
3663
        
 
3664
        public class QueryExpressionIntoClause : QueryExpressionClause {
 
3665
                
 
3666
                string intoIdentifier;
 
3667
                
 
3668
                QueryExpression continuedQuery;
 
3669
                
 
3670
                public string IntoIdentifier {
 
3671
                        get {
 
3672
                                return intoIdentifier;
 
3673
                        }
 
3674
                        set {
 
3675
                                intoIdentifier = string.IsNullOrEmpty(value) ? "?" : value;
 
3676
                        }
 
3677
                }
 
3678
                
 
3679
                public QueryExpression ContinuedQuery {
 
3680
                        get {
 
3681
                                return continuedQuery;
 
3682
                        }
 
3683
                        set {
 
3684
                                continuedQuery = value ?? QueryExpression.Null;
 
3685
                                if (!continuedQuery.IsNull) continuedQuery.Parent = this;
 
3686
                        }
 
3687
                }
 
3688
                
 
3689
                public QueryExpressionIntoClause() {
 
3690
                        intoIdentifier = "?";
 
3691
                        continuedQuery = QueryExpression.Null;
 
3692
                }
 
3693
                
 
3694
                public new static QueryExpressionIntoClause Null {
 
3695
                        get {
 
3696
                                return NullQueryExpressionIntoClause.Instance;
 
3697
                        }
 
3698
                }
 
3699
                
 
3700
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3701
                        return visitor.VisitQueryExpressionIntoClause(this, data);
 
3702
                }
 
3703
                
 
3704
                public override string ToString() {
 
3705
                        return string.Format("[QueryExpressionIntoClause IntoIdentifier={0} ContinuedQuery={1}]", IntoIdentifier, ContinuedQuery);
 
3706
                }
 
3707
        }
 
3708
        
 
3709
        internal sealed class NullQueryExpressionIntoClause : QueryExpressionIntoClause {
 
3710
                
 
3711
                internal static NullQueryExpressionIntoClause Instance = new NullQueryExpressionIntoClause();
 
3712
                
 
3713
                public override bool IsNull {
 
3714
                        get {
 
3715
                                return true;
 
3716
                        }
 
3717
                }
 
3718
                
 
3719
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3720
                        return null;
 
3721
                }
 
3722
                
 
3723
                public override string ToString() {
 
3724
                        return "[NullQueryExpressionIntoClause]";
 
3725
                }
 
3726
        }
 
3727
        
 
3728
        public class QueryExpressionJoinClause : QueryExpressionFromOrJoinClause {
 
3729
                
 
3730
                Expression onExpression;
 
3731
                
 
3732
                Expression equalsExpression;
 
3733
                
 
3734
                string intoIdentifier;
 
3735
                
 
3736
                public Expression OnExpression {
 
3737
                        get {
 
3738
                                return onExpression;
 
3739
                        }
 
3740
                        set {
 
3741
                                onExpression = value ?? Expression.Null;
 
3742
                                if (!onExpression.IsNull) onExpression.Parent = this;
 
3743
                        }
 
3744
                }
 
3745
                
 
3746
                public Expression EqualsExpression {
 
3747
                        get {
 
3748
                                return equalsExpression;
 
3749
                        }
 
3750
                        set {
 
3751
                                equalsExpression = value ?? Expression.Null;
 
3752
                                if (!equalsExpression.IsNull) equalsExpression.Parent = this;
 
3753
                        }
 
3754
                }
 
3755
                
 
3756
                public string IntoIdentifier {
 
3757
                        get {
 
3758
                                return intoIdentifier;
 
3759
                        }
 
3760
                        set {
 
3761
                                intoIdentifier = value ?? "";
 
3762
                        }
 
3763
                }
 
3764
                
 
3765
                public QueryExpressionJoinClause() {
 
3766
                        onExpression = Expression.Null;
 
3767
                        equalsExpression = Expression.Null;
 
3768
                        intoIdentifier = "";
 
3769
                }
 
3770
                
 
3771
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3772
                        return visitor.VisitQueryExpressionJoinClause(this, data);
 
3773
                }
 
3774
                
 
3775
                public override string ToString() {
 
3776
                        return string.Format("[QueryExpressionJoinClause OnExpression={0} EqualsExpression={1} IntoIdentifier={" +
 
3777
                                        "2} Type={3} Identifier={4} InExpression={5}]", OnExpression, EqualsExpression, IntoIdentifier, Type, Identifier, InExpression);
 
3778
                }
 
3779
        }
 
3780
        
 
3781
        public class QueryExpressionLetClause : QueryExpressionClause {
 
3782
                
 
3783
                string identifier;
 
3784
                
 
3785
                Expression expression;
 
3786
                
 
3787
                public string Identifier {
 
3788
                        get {
 
3789
                                return identifier;
 
3790
                        }
 
3791
                        set {
 
3792
                                identifier = string.IsNullOrEmpty(value) ? "?" : value;
 
3793
                        }
 
3794
                }
 
3795
                
 
3796
                public Expression Expression {
 
3797
                        get {
 
3798
                                return expression;
 
3799
                        }
 
3800
                        set {
 
3801
                                expression = value ?? Expression.Null;
 
3802
                                if (!expression.IsNull) expression.Parent = this;
 
3803
                        }
 
3804
                }
 
3805
                
 
3806
                public QueryExpressionLetClause() {
 
3807
                        identifier = "?";
 
3808
                        expression = Expression.Null;
 
3809
                }
 
3810
                
 
3811
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3812
                        return visitor.VisitQueryExpressionLetClause(this, data);
 
3813
                }
 
3814
                
 
3815
                public override string ToString() {
 
3816
                        return string.Format("[QueryExpressionLetClause Identifier={0} Expression={1}]", Identifier, Expression);
 
3817
                }
 
3818
        }
 
3819
        
 
3820
        public class QueryExpressionOrderClause : QueryExpressionClause {
 
3821
                
 
3822
                List<QueryExpressionOrdering> orderings;
 
3823
                
 
3824
                public List<QueryExpressionOrdering> Orderings {
 
3825
                        get {
 
3826
                                return orderings;
 
3827
                        }
 
3828
                        set {
 
3829
                                orderings = value ?? new List<QueryExpressionOrdering>();
 
3830
                        }
 
3831
                }
 
3832
                
 
3833
                public QueryExpressionOrderClause() {
 
3834
                        orderings = new List<QueryExpressionOrdering>();
 
3835
                }
 
3836
                
 
3837
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3838
                        return visitor.VisitQueryExpressionOrderClause(this, data);
 
3839
                }
 
3840
                
 
3841
                public override string ToString() {
 
3842
                        return string.Format("[QueryExpressionOrderClause Orderings={0}]", GetCollectionString(Orderings));
 
3843
                }
 
3844
        }
 
3845
        
 
3846
        public class QueryExpressionOrdering : AbstractNode {
 
3847
                
 
3848
                Expression criteria;
 
3849
                
 
3850
                QueryExpressionOrderingDirection direction;
 
3851
                
 
3852
                public Expression Criteria {
 
3853
                        get {
 
3854
                                return criteria;
 
3855
                        }
 
3856
                        set {
 
3857
                                criteria = value ?? Expression.Null;
 
3858
                                if (!criteria.IsNull) criteria.Parent = this;
 
3859
                        }
 
3860
                }
 
3861
                
 
3862
                public QueryExpressionOrderingDirection Direction {
 
3863
                        get {
 
3864
                                return direction;
 
3865
                        }
 
3866
                        set {
 
3867
                                direction = value;
 
3868
                        }
 
3869
                }
 
3870
                
 
3871
                public QueryExpressionOrdering() {
 
3872
                        criteria = Expression.Null;
 
3873
                }
 
3874
                
 
3875
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3876
                        return visitor.VisitQueryExpressionOrdering(this, data);
 
3877
                }
 
3878
                
 
3879
                public override string ToString() {
 
3880
                        return string.Format("[QueryExpressionOrdering Criteria={0} Direction={1}]", Criteria, Direction);
 
3881
                }
 
3882
        }
 
3883
        
 
3884
        public class QueryExpressionSelectClause : QueryExpressionClause {
 
3885
                
 
3886
                Expression projection;
 
3887
                
 
3888
                public Expression Projection {
 
3889
                        get {
 
3890
                                return projection;
 
3891
                        }
 
3892
                        set {
 
3893
                                projection = value ?? Expression.Null;
 
3894
                                if (!projection.IsNull) projection.Parent = this;
 
3895
                        }
 
3896
                }
 
3897
                
 
3898
                public QueryExpressionSelectClause() {
 
3899
                        projection = Expression.Null;
 
3900
                }
 
3901
                
 
3902
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3903
                        return visitor.VisitQueryExpressionSelectClause(this, data);
 
3904
                }
 
3905
                
 
3906
                public override string ToString() {
 
3907
                        return string.Format("[QueryExpressionSelectClause Projection={0}]", Projection);
 
3908
                }
 
3909
        }
 
3910
        
 
3911
        public class QueryExpressionWhereClause : QueryExpressionClause {
 
3912
                
 
3913
                Expression condition;
 
3914
                
 
3915
                public Expression Condition {
 
3916
                        get {
 
3917
                                return condition;
 
3918
                        }
 
3919
                        set {
 
3920
                                condition = value ?? Expression.Null;
 
3921
                                if (!condition.IsNull) condition.Parent = this;
 
3922
                        }
 
3923
                }
 
3924
                
 
3925
                public QueryExpressionWhereClause() {
 
3926
                        condition = Expression.Null;
 
3927
                }
 
3928
                
 
3929
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
 
3930
                        return visitor.VisitQueryExpressionWhereClause(this, data);
 
3931
                }
 
3932
                
 
3933
                public override string ToString() {
 
3934
                        return string.Format("[QueryExpressionWhereClause Condition={0}]", Condition);
 
3935
                }
 
3936
        }
 
3937
        
3405
3938
        public class RaiseEventStatement : Statement {
3406
3939
                
3407
3940
                string eventName;
3759
4292
                        }
3760
4293
                }
3761
4294
                
3762
 
                public TemplateDefinition(string name, List<AttributeSection> attributes) : 
3763
 
                                base(attributes) {
 
4295
                public TemplateDefinition(string name, List<AttributeSection> attributes) {
3764
4296
                        Name = name;
 
4297
                        Attributes = attributes;
3765
4298
                        bases = new List<TypeReference>();
3766
4299
                }
3767
4300
                
3924
4457
                        }
3925
4458
                }
3926
4459
                
3927
 
                public TypeDeclaration(Modifiers modifier, List<AttributeSection> attributes) : 
3928
 
                                base(attributes) {
 
4460
                public TypeDeclaration(Modifiers modifier, List<AttributeSection> attributes) {
3929
4461
                        Modifier = modifier;
 
4462
                        Attributes = attributes;
3930
4463
                        name = "";
3931
4464
                        baseTypes = new List<TypeReference>();
3932
4465
                        templates = new List<TemplateDefinition>();
4227
4760
                        Usings = usings;
4228
4761
                }
4229
4762
                
 
4763
public UsingDeclaration(string @namespace) : this(@namespace, null) {}
 
4764
                
4230
4765
public UsingDeclaration(string @namespace, TypeReference alias) { usings = new List<Using>(1); usings.Add(new Using(@namespace, alias)); }
4231
4766
                
4232
 
public UsingDeclaration(string @namespace) : this(@namespace, null) {}
4233
 
                
4234
4767
                public override object AcceptVisitor(IAstVisitor visitor, object data) {
4235
4768
                        return visitor.VisitUsingDeclaration(this, data);
4236
4769
                }