| ... | @@ -946,13 +946,13 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation { | ... | @@ -946,13 +946,13 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation { |
| 946 | }; | 946 | }; |
| 947 | | 947 | |
| 948 | const lto = blk: { | 948 | const lto = blk: { |
| 949 | if (options.want_lto) |explicit| { | 949 | if (options.want_lto) |want_lto| { |
| 950 | if (!use_lld and !options.target.isDarwin()) | 950 | if (want_lto and !use_lld and !options.target.isDarwin()) |
| 951 | return error.LtoUnavailableWithoutLld; | 951 | return error.LtoUnavailableWithoutLld; |
| 952 | break :blk explicit; | 952 | break :blk want_lto; |
| 953 | } else if (!use_lld) { | 953 | } else if (!use_lld) { |
| 954 | // TODO zig ld LTO support | 954 | // zig ld LTO support is tracked by |
| 955 | // See https://github.com/ziglang/zig/issues/8680 | 955 | // https://github.com/ziglang/zig/issues/8680 |
| 956 | break :blk false; | 956 | break :blk false; |
| 957 | } else if (options.c_source_files.len == 0) { | 957 | } else if (options.c_source_files.len == 0) { |
| 958 | break :blk false; | 958 | break :blk false; |