Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1237)

Unified Diff: fusl/src/math/logb.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: fusl/src/math/logb.c
diff --git a/fusl/src/math/logb.c b/fusl/src/math/logb.c
index 7f8bdfae19f8ca0a85b611d38a73695ccf588e43..bff51015f424589af88a217f8d76d17fb28469fd 100644
--- a/fusl/src/math/logb.c
+++ b/fusl/src/math/logb.c
@@ -2,16 +2,15 @@
/*
special cases:
- logb(+-0) = -inf, and raise divbyzero
- logb(+-inf) = +inf
- logb(nan) = nan
+ logb(+-0) = -inf, and raise divbyzero
+ logb(+-inf) = +inf
+ logb(nan) = nan
*/
-double logb(double x)
-{
- if (!isfinite(x))
- return x * x;
- if (x == 0)
- return -1/(x*x);
- return ilogb(x);
+double logb(double x) {
+ if (!isfinite(x))
+ return x * x;
+ if (x == 0)
+ return -1 / (x * x);
+ return ilogb(x);
}

Powered by Google App Engine
This is Rietveld 408576698