diff options
| author | Jakub Konka <kubkon@jakubkonka.com> | 2020-12-03 21:57:26 +0100 |
|---|---|---|
| committer | Jakub Konka <kubkon@jakubkonka.com> | 2020-12-03 21:57:26 +0100 |
| commit | d3be4992708e7e6631df52fb5f4ccb0f521a77de (patch) | |
| tree | 98a510e9642674b50d703f406db9d57ef3c42269 /src/main.zig | |
| parent | 5cba16c707fd4c46aeeabebdcc85d06b9149d6e4 (diff) | |
| download | zig-d3be4992708e7e6631df52fb5f4ccb0f521a77de.tar.gz zig-d3be4992708e7e6631df52fb5f4ccb0f521a77de.zip | |
lld+macho: address review comments
Diffstat (limited to 'src/main.zig')
| -rw-r--r-- | src/main.zig | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/src/main.zig b/src/main.zig index b69a019d71..ca4a8ebe2b 100644 --- a/src/main.zig +++ b/src/main.zig @@ -1773,17 +1773,7 @@ fn buildOutputType( error.SemanticAnalyzeFail => process.exit(1), else => |e| return e, }; - switch (output_mode) { - .Exe => try comp.makeBinFileExecutable(), - .Lib => { - if (link_mode) |lm| { - if (lm == .Dynamic) { - try comp.makeBinFileExecutable(); - } - } - }, - else => {}, - } + try comp.makeBinFileExecutable(); if (build_options.is_stage1 and comp.stage1_lock != null and watch) { warn("--watch is not recommended with the stage1 backend; it leaks memory and is not capable of incremental compilation", .{}); @@ -1882,9 +1872,7 @@ fn buildOutputType( while (watch) { try stderr.print("(zig) ", .{}); - if (output_mode == .Exe) { - try comp.makeBinFileExecutable(); - } + try comp.makeBinFileExecutable(); if (stdin.readUntilDelimiterOrEof(&repl_buf, '\n') catch |err| { try stderr.print("\nUnable to parse command: {}\n", .{@errorName(err)}); continue; |
