diff options
author | Chris Lattner <sabre@nondot.org> | 2011-07-18 04:54:35 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2011-07-18 04:54:35 +0000 |
commit | db125cfaf57cc83e7dd7453de2d509bc8efd0e5e (patch) | |
tree | a163ac0f83da7be3f9675a122a6144b12418be09 /unittests/Support/TypeBuilderTest.cpp | |
parent | 4b3d5469fb7c25504fa20dc65640f02d79675d48 (diff) | |
download | llvm-db125cfaf57cc83e7dd7453de2d509bc8efd0e5e.tar.gz llvm-db125cfaf57cc83e7dd7453de2d509bc8efd0e5e.tar.bz2 llvm-db125cfaf57cc83e7dd7453de2d509bc8efd0e5e.tar.xz |
land David Blaikie's patch to de-constify Type, with a few tweaks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135375 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/Support/TypeBuilderTest.cpp')
-rw-r--r-- | unittests/Support/TypeBuilderTest.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/unittests/Support/TypeBuilderTest.cpp b/unittests/Support/TypeBuilderTest.cpp index 06091784cf..6e3fbc231f 100644 --- a/unittests/Support/TypeBuilderTest.cpp +++ b/unittests/Support/TypeBuilderTest.cpp @@ -184,14 +184,14 @@ class MyPortableType { namespace llvm { template<bool cross> class TypeBuilder<MyType, cross> { public: - static const StructType *get(LLVMContext &Context) { + static StructType *get(LLVMContext &Context) { // Using the static result variable ensures that the type is // only looked up once. std::vector<Type*> st; st.push_back(TypeBuilder<int, cross>::get(Context)); st.push_back(TypeBuilder<int*, cross>::get(Context)); st.push_back(TypeBuilder<void*[], cross>::get(Context)); - static const StructType *const result = StructType::get(Context, st); + static StructType *const result = StructType::get(Context, st); return result; } @@ -207,14 +207,14 @@ public: template<bool cross> class TypeBuilder<MyPortableType, cross> { public: - static const StructType *get(LLVMContext &Context) { + static StructType *get(LLVMContext &Context) { // Using the static result variable ensures that the type is // only looked up once. std::vector<Type*> st; st.push_back(TypeBuilder<types::i<32>, cross>::get(Context)); st.push_back(TypeBuilder<types::i<32>*, cross>::get(Context)); st.push_back(TypeBuilder<types::i<8>*[], cross>::get(Context)); - static const StructType *const result = StructType::get(Context, st); + static StructType *const result = StructType::get(Context, st); return result; } |