File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 1
- using System . Linq ;
1
+ using System . Collections . Generic ;
2
+ using System . Linq ;
2
3
using Cmc ;
3
4
using Cmc . Core ;
4
5
using Cmc . Decl ;
6
+ using Cmc . Expr ;
5
7
using Cmc . Stmt ;
6
8
using Microsoft . VisualStudio . TestTools . UnitTesting ;
7
9
@@ -14,6 +16,14 @@ public class StructTests
14
16
public void StructTest1 ( )
15
17
{
16
18
var @struct = new StatementList ( MetaData . Empty ,
19
+ new StructDeclaration ( MetaData . Empty , "Person" ,
20
+ new List < VariableDeclaration > ( new [ ]
21
+ {
22
+ new VariableDeclaration ( MetaData . Empty , "name" ,
23
+ new StringLiteralExpression ( MetaData . Empty , "ice" ) ) ,
24
+ new VariableDeclaration ( MetaData . Empty , "gender" ,
25
+ new IntLiteralExpression ( MetaData . Empty , "123" , false ) )
26
+ } ) ) ,
17
27
new VariableDeclaration ( MetaData . Empty , "var" , type :
18
28
new UnknownType ( MetaData . Empty , "Person" ) ) ) ;
19
29
@struct . SurroundWith ( Environment . SolarSystem ) ;
You can’t perform that action at this time.
0 commit comments