summaryrefslogtreecommitdiff
path: root/lib/ashlti3.c
diff options
context:
space:
mode:
authorEdward O'Callaghan <eocallaghan@auroraux.org>2009-08-09 18:41:02 +0000
committerEdward O'Callaghan <eocallaghan@auroraux.org>2009-08-09 18:41:02 +0000
commit8bf1e094893cb24796137b47ee0d46d18d299996 (patch)
tree57669837db32d106ba744be339a354b8055fcfe4 /lib/ashlti3.c
parent33c134702e274fdbcb1672771a137efb82b498b2 (diff)
downloadcompiler-rt-8bf1e094893cb24796137b47ee0d46d18d299996.tar.gz
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
Diffstat (limited to 'lib/ashlti3.c')
-rw-r--r--lib/ashlti3.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/ashlti3.c b/lib/ashlti3.c
index c1ab37163..317de6655 100644
--- a/lib/ashlti3.c
+++ b/lib/ashlti3.c
@@ -29,15 +29,15 @@ __ashlti3(ti_int a, si_int b)
input.all = a;
if (b & bits_in_dword) /* bits_in_dword <= b < bits_in_tword */
{
- result.low = 0;
- result.high = input.low << (b - bits_in_dword);
+ result.s.low = 0;
+ result.s.high = input.s.low << (b - bits_in_dword);
}
else /* 0 <= b < bits_in_dword */
{
if (b == 0)
return a;
- result.low = input.low << b;
- result.high = (input.high << b) | (input.low >> (bits_in_dword - b));
+ result.s.low = input.s.low << b;
+ result.s.high = (input.s.high << b) | (input.s.low >> (bits_in_dword - b));
}
return result.all;
}