PageRenderTime 15ms CodeModel.GetById 11ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/trunk/Examples/test-suite/d/special_variable_macros_runme.2.d

#
D | 21 lines | 17 code | 4 blank | 0 comment | 7 complexity | 6e9730fa71f06d10af0f0c6a3c15d515 MD5 | raw file
 1module special_variable_macros_runme;
 2
 3import std.exception;
 4import special_variable_macros.special_variable_macros;
 5import special_variable_macros.Name;
 6import special_variable_macros.NewName;
 7import special_variable_macros.PairIntBool;
 8
 9void main() {
10  auto name = new Name();
11  enforce(testFred(name) == "none");
12  enforce(testJack(name) == "$specialname");
13  enforce(testJill(name) == "jilly");
14  enforce(testMary(name) == "SWIGTYPE_p_NameWrap");
15  enforce(testJim(name) == "multiname num");
16
17  enforce(testJohn(new PairIntBool(10, false)) == 123);
18
19  auto newName = NewName.factory("factoryname");
20  enforce(newName.getStoredName().getName() == "factoryname");
21}