Refactor to remove un-named struct gnu extension usage. Now ISO C89 and C99 compliant. Comment trailing endifs
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@78537 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/ffsdi2.c b/lib/ffsdi2.c
index 680fdb3..8c03d19 100644
--- a/lib/ffsdi2.c
+++ b/lib/ffsdi2.c
@@ -23,11 +23,11 @@
{
dwords x;
x.all = a;
- if (x.low == 0)
+ if (x.s.low == 0)
{
- if (x.high == 0)
+ if (x.s.high == 0)
return 0;
- return __builtin_ctz(x.high) + (1 + sizeof(si_int) * CHAR_BIT);
+ return __builtin_ctz(x.s.high) + (1 + sizeof(si_int) * CHAR_BIT);
}
- return __builtin_ctz(x.low) + 1;
+ return __builtin_ctz(x.s.low) + 1;
}