authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2016-01-11 20:43:48-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2016-01-11 20:44:10-07:00
logcb46d0b5b0d1d83856adab34b461049f5cfac019
treeb1aff76b3fd220242a9bc0cc265cfbf28dd70477
parentccc8e9f4c328cb29fa7f21101d8c20fd23e4942a

fix not adding builtin functions code


3 files changed, 10 insertions(+), 20 deletions(-)

README.md+4-4
......@@ -45,10 +45,10 @@ compromises backward compatibility.
4545### Current Status
4646
4747 * Have a look in the examples/ folder to see some code examples.
48 * Some language features available such as loops, inline assembly, expressions,
49 literals, functions, importing other files.
50 * Only Linux x86_64 is supported.
51 * Only building for the native target is supported.
48 * Basic language features available such as loops, inline assembly,
49 expressions, literals, functions, importing, structs, enums.
50 * Linux x86_64 is supported.
51 * Building for the native target is supported.
5252 * Optimized machine code that Zig produces is indistinguishable from
5353 optimized machine code produced from equivalent C program.
5454 * Zig can generate dynamic libraries, executables, object files, and C
src/codegen.cpp+1-2
......@@ -2748,8 +2748,7 @@ void codegen_add_root_code(CodeGen *g, Buf *src_dir, Buf *src_basename, Buf *sou
27482748 g->bootstrap_import = add_special_code(g, "bootstrap.zig");
27492749 }
27502750
2751 // TODO re-enable this
2752 //add_special_code(g, "builtin.zig");
2751 add_special_code(g, "builtin.zig");
27532752 }
27542753
27552754 if (g->verbose) {
test/run_tests.cpp+5-14
......@@ -1033,19 +1033,6 @@ fn print_ok(val: #typeof(x)) -> #typeof(foo) {
10331033const foo : i32 = 0;
10341034 )SOURCE", "OK\n");
10351035
1036 add_simple_case("enum with void types", R"SOURCE(
1037use "std.zig";
1038enum Foo { A, B, C, D, }
1039pub fn main(argc: isize, argv: &&u8, env: &&u8) -> i32 {
1040 const foo : Foo = Foo.B;
1041 if (foo != Foo.B) {
1042 print_str("BAD\n");
1043 }
1044 print_str("OK\n");
1045 return 0;
1046}
1047 )SOURCE", "OK\n");
1048
10491036 add_simple_case("enum type", R"SOURCE(
10501037use "std.zig";
10511038
......@@ -1070,7 +1057,11 @@ enum Bar {
10701057pub fn main(argc: isize, argv: &&u8, env: &&u8) -> i32 {
10711058 const foo1 = Foo.One(13);
10721059 const foo2 = Foo.Two(Point { .x = 1234, .y = 5678, });
1073 const bar = Bar.A;
1060 const bar = Bar.B;
1061
1062 if (bar != Bar.B) {
1063 print_str("BAD\n");
1064 }
10741065
10751066 if (#value_count(Foo) != 3) {
10761067 print_str("BAD\n");