diff options
| author | Andrew Kelley <superjoe30@gmail.com> | 2017-12-22 00:50:30 -0500 |
|---|---|---|
| committer | Andrew Kelley <superjoe30@gmail.com> | 2017-12-22 00:50:30 -0500 |
| commit | d917815d8111b98dc237cbe2c723fa63018e02b1 (patch) | |
| tree | ce12771a86b2412ee9692ca73d3ca49abe5da3ce /std/math/expm1.zig | |
| parent | 8bc523219c66427951e5339550502871547f2138 (diff) | |
| download | zig-d917815d8111b98dc237cbe2c723fa63018e02b1.tar.gz zig-d917815d8111b98dc237cbe2c723fa63018e02b1.zip | |
explicitly return from blocks
instead of last statement being expression value
closes #629
Diffstat (limited to 'std/math/expm1.zig')
| -rw-r--r-- | std/math/expm1.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/std/math/expm1.zig b/std/math/expm1.zig index ef0b2766b1..14a69958e8 100644 --- a/std/math/expm1.zig +++ b/std/math/expm1.zig @@ -9,11 +9,11 @@ const assert = @import("../debug.zig").assert; pub fn expm1(x: var) -> @typeOf(x) { const T = @typeOf(x); - switch (T) { + return switch (T) { f32 => @inlineCall(expm1_32, x), f64 => @inlineCall(expm1_64, x), else => @compileError("exp1m not implemented for " ++ @typeName(T)), - } + }; } fn expm1_32(x_: f32) -> f32 { |
