| author | |
| committer | |
| log | cfaced3f73da2d5fc82f063715d51e06084baee8 |
| tree | a1a5b3d2f51bda2557f14bbe9a90341571444103 |
| parent | 768a9780ca26166b4481c06e87bc6d090be71b64 |
5 files changed, 8 insertions(+), 8 deletions(-)
example/cat/main.zig+3-3| ... | ... | @@ -17,7 +17,7 @@ pub fn main(args: [][]u8) -> %void { |
| 17 | 17 | var is: io.InStream = undefined; |
| 18 | 18 | is.open(arg) %% |err| { |
| 19 | 19 | %%io.stderr.printf("Unable to open file: "); |
| 20 | %%io.stderr.printf(@errName(err)); | |
| 20 | %%io.stderr.printf(@errorName(err)); | |
| 21 | 21 | %%io.stderr.printf("\n"); |
| 22 | 22 | return err; |
| 23 | 23 | }; |
| ... | ... | @@ -46,7 +46,7 @@ fn cat_stream(is: io.InStream) -> %void { |
| 46 | 46 | while (true) { |
| 47 | 47 | const bytes_read = is.read(buf) %% |err| { |
| 48 | 48 | %%io.stderr.printf("Unable to read from stream: "); |
| 49 | %%io.stderr.printf(@errName(err)); | |
| 49 | %%io.stderr.printf(@errorName(err)); | |
| 50 | 50 | %%io.stderr.printf("\n"); |
| 51 | 51 | return err; |
| 52 | 52 | }; |
| ... | ... | @@ -57,7 +57,7 @@ fn cat_stream(is: io.InStream) -> %void { |
| 57 | 57 | |
| 58 | 58 | io.stdout.write(buf[0...bytes_read]) %% |err| { |
| 59 | 59 | %%io.stderr.printf("Unable to write to stdout: "); |
| 60 | %%io.stderr.printf(@errName(err)); | |
| 60 | %%io.stderr.printf(@errorName(err)); | |
| 61 | 61 | %%io.stderr.printf("\n"); |
| 62 | 62 | return err; |
| 63 | 63 | }; |
example/guess_number/main.zig+1-1| ... | ... | @@ -19,7 +19,7 @@ pub fn main(args: [][]u8) -> %void { |
| 19 | 19 | |
| 20 | 20 | const line_len = io.stdin.read(line_buf) %% |err| { |
| 21 | 21 | %%io.stdout.printf("Unable to read from stdin: "); |
| 22 | %%io.stdout.printf(@errName(err)); | |
| 22 | %%io.stdout.printf(@errorName(err)); | |
| 23 | 23 | %%io.stdout.printf("\n"); |
| 24 | 24 | return err; |
| 25 | 25 | }; |
src/codegen.cpp+1-1| ... | ... | @@ -4843,7 +4843,7 @@ static void define_builtin_fns(CodeGen *g) { |
| 4843 | 4843 | create_builtin_fn_with_arg_count(g, BuiltinFnIdClz, "clz", 2); |
| 4844 | 4844 | create_builtin_fn_with_arg_count(g, BuiltinFnIdImport, "import", 1); |
| 4845 | 4845 | create_builtin_fn_with_arg_count(g, BuiltinFnIdCImport, "cImport", 1); |
| 4846 | create_builtin_fn_with_arg_count(g, BuiltinFnIdErrName, "errName", 1); | |
| 4846 | create_builtin_fn_with_arg_count(g, BuiltinFnIdErrName, "errorName", 1); | |
| 4847 | 4847 | create_builtin_fn_with_arg_count(g, BuiltinFnIdEmbedFile, "embedFile", 1); |
| 4848 | 4848 | create_builtin_fn_with_arg_count(g, BuiltinFnIdCmpExchange, "cmpxchg", 5); |
| 4849 | 4849 | create_builtin_fn_with_arg_count(g, BuiltinFnIdFence, "fence", 1); |
std/mem.zig+1-1| ... | ... | @@ -19,7 +19,7 @@ pub struct Allocator { |
| 19 | 19 | alloc(self, T, n) %% |err| { |
| 20 | 20 | // TODO var args printf |
| 21 | 21 | %%io.stderr.write("allocation failure: "); |
| 22 | %%io.stderr.write(@errName(err)); | |
| 22 | %%io.stderr.write(@errorName(err)); | |
| 23 | 23 | %%io.stderr.printf("\n"); |
| 24 | 24 | os.abort() |
| 25 | 25 | } |
test/self_hosted.zig+2-2| ... | ... | @@ -766,8 +766,8 @@ error AnError; |
| 766 | 766 | error ALongerErrorName; |
| 767 | 767 | #attribute("test") |
| 768 | 768 | fn errorNameString() { |
| 769 | assert(str.eql(@errName(error.AnError), "AnError")); | |
| 770 | assert(str.eql(@errName(error.ALongerErrorName), "ALongerErrorName")); | |
| 769 | assert(str.eql(@errorName(error.AnError), "AnError")); | |
| 770 | assert(str.eql(@errorName(error.ALongerErrorName), "ALongerErrorName")); | |
| 771 | 771 | } |
| 772 | 772 | |
| 773 | 773 |