]> granicus.if.org Git - llvm/commit
[APInt] Add a public typedef for the internal type of APInt use it instead of integer...
authorCraig Topper <craig.topper@gmail.com>
Sun, 2 Apr 2017 19:17:22 +0000 (19:17 +0000)
committerCraig Topper <craig.topper@gmail.com>
Sun, 2 Apr 2017 19:17:22 +0000 (19:17 +0000)
commit6b60db9e917fdc394d19a990d49563fce37d4c25
treed248f7245253a6b8f028aa5aff39585e85068022
parent9071ac1443ff6fd0417f42d89b887f7fe4b17e50
[APInt] Add a public typedef for the internal type of APInt use it instead of integerPart. Make APINT_BITS_PER_WORD and APINT_WORD_SIZE public.

This patch is one step to attempt to unify the main APInt interface and the tc functions used by APFloat.

This patch adds a WordType to APInt and uses that in all the tc functions. I've added temporary typedefs to APFloat to alias it to integerPart to keep the patch size down. I'll work on removing that in a future patch.

In future patches I hope to reuse the tc functions to implement some of the main APInt functionality.

I may remove APINT_ from BITS_PER_WORD and WORD_SIZE constants so that we don't have the repetitive APInt::APINT_ externally.

Differential Revision: https://reviews.llvm.org/D31523

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@299341 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/ADT/APFloat.h
include/llvm/ADT/APInt.h
lib/Support/APFloat.cpp
lib/Support/APInt.cpp
unittests/ADT/APIntTest.cpp