public static void TestIncompleteArrayType() { var type = new ABT.IncompleteArrayType( new ABT.LongType(isConst: true) ); Assert.AreEqual("const long a[]", type.Decl("a")); Assert.AreEqual("const long []", type.Decl()); type = new ABT.IncompleteArrayType( new ABT.IncompleteArrayType( new ABT.LongType() ) ); Assert.AreEqual("long a[][]", type.Decl("a")); Assert.AreEqual("long [][]", type.Decl()); }
public static void TestIncompleteArrayType() { var type = new ABT.IncompleteArrayType( new ABT.LongType(isConst: true) ); Assert.AreEqual("const long a[]", type.Decl("a")); Assert.AreEqual("const long []", type.Decl()); type = new ABT.IncompleteArrayType( new ABT.IncompleteArrayType( new ABT.LongType() ) ); Assert.AreEqual("long a[][]", type.Decl("a")); Assert.AreEqual("long [][]", type.Decl()); }