| ... | ... | @@ -1,18 +1,14 @@ |
| 1 | 1 | const builtin = @import("builtin"); |
| 2 | 2 | const std = @import("std"); |
| 3 | 3 | |
| 4 | | pub const linkage: std.builtin.GlobalLinkage = if (builtin.is_test) |
| 5 | | .internal |
| 6 | | else |
| 7 | | .strong; |
| 4 | /// It is incorrect to make this conditional on `builtin.is_test`, because it is possible that |
| 5 | /// libzigc is being linked into a different test compilation, as opposed to being tested itself. |
| 6 | pub const linkage: std.builtin.GlobalLinkage = .strong; |
| 8 | 7 | |
| 9 | 8 | /// Determines the symbol's visibility to other objects. |
| 10 | 9 | /// For WebAssembly this allows the symbol to be resolved to other modules, but will not |
| 11 | 10 | /// export it to the host runtime. |
| 12 | | pub const visibility: std.builtin.SymbolVisibility = if (linkage != .internal) |
| 13 | | .hidden |
| 14 | | else |
| 15 | | .default; |
| 11 | pub const visibility: std.builtin.SymbolVisibility = .hidden; |
| 16 | 12 | |
| 17 | 13 | /// Given a low-level syscall return value, sets errno and returns `-1`, or on |
| 18 | 14 | /// success returns the result. |