diff options
| author | Jimmi HC <jhc@liab.dk> | 2018-06-05 11:14:43 +0200 |
|---|---|---|
| committer | Jimmi HC <jhc@liab.dk> | 2018-06-05 11:14:43 +0200 |
| commit | 02cb220faf0d527b656a3a87ec96e6738770c8e6 (patch) | |
| tree | 5d79c58df7d786e3fa8adc0bc382fffa3ccafe60 /std/math/log2.zig | |
| parent | e53b683bd3958a7b1c517e2391edce42b9d4e48b (diff) | |
| download | zig-02cb220faf0d527b656a3a87ec96e6738770c8e6.tar.gz zig-02cb220faf0d527b656a3a87ec96e6738770c8e6.zip | |
Renamed "(int/float literal)" to "comptime_int/float"
Diffstat (limited to 'std/math/log2.zig')
| -rw-r--r-- | std/math/log2.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/std/math/log2.zig b/std/math/log2.zig index 22cc8082b3..2530519941 100644 --- a/std/math/log2.zig +++ b/std/math/log2.zig @@ -14,7 +14,7 @@ const TypeId = builtin.TypeId; pub fn log2(x: var) @typeOf(x) { const T = @typeOf(x); switch (@typeId(T)) { - TypeId.FloatLiteral => { + TypeId.ComptimeFloat => { return @typeOf(1.0)(log2_64(x)); }, TypeId.Float => { @@ -24,7 +24,7 @@ pub fn log2(x: var) @typeOf(x) { else => @compileError("log2 not implemented for " ++ @typeName(T)), }; }, - TypeId.IntLiteral => comptime { + TypeId.ComptimeInt => comptime { var result = 0; var x_shifted = x; while (b: { |
