diff --git a/src/include/util/impl/integral.H b/src/include/util/impl/integral.H index b814e2655de..9cc39b222b2 100644 --- a/src/include/util/impl/integral.H +++ b/src/include/util/impl/integral.H @@ -1,7 +1,7 @@ /* IBM_PROLOG_BEGIN_TAG */ /* This is an automatically generated prolog. */ /* */ -/* $Source: src/include/util/traits/integral.H $ */ +/* $Source: src/include/util/impl/integral.H $ */ /* */ /* OpenPOWER HostBoot Project */ /* */ @@ -38,9 +38,8 @@ namespace std constexpr value_type operator()() const { return value; } }; - struct true_type : integral_constant {}; - struct false_type : integral_constant {}; - + typedef integral_constant true_type; + typedef integral_constant false_type; } #endif /* vim: set filetype=cpp : */ diff --git a/src/usr/testcore/lib/integral.H b/src/usr/testcore/lib/integral.H index 74750582ed4..bead1c03fa3 100644 --- a/src/usr/testcore/lib/integral.H +++ b/src/usr/testcore/lib/integral.H @@ -82,6 +82,21 @@ class STLIntegralTest : public CxxTest::TestSuite TS_FAIL("false_type is not false."); } } + + void testTypes() + { + if (!std::is_same >::value) + { + TS_FAIL("true_type and integral_constant are not the same type."); + } + + if (!std::is_same >::value) + { + TS_FAIL("true_type and integral_constant are not the same type."); + } + } }; #endif diff --git a/src/usr/testcore/lib/makefile b/src/usr/testcore/lib/makefile index ea4b74ee48d..35c3a389597 100644 --- a/src/usr/testcore/lib/makefile +++ b/src/usr/testcore/lib/makefile @@ -27,11 +27,12 @@ ROOTPATH = ../../../.. MODULE = testsyslib #@TODO-RTC:151185-Turn enable all test cases #TESTS = *.H -TESTS = stltest.H #TODO RTC:204720 #TESTS += synctest.H -TESTS += tls.H +TESTS = stltest.H +TESTS += tls.H +TESTS += integral.H SUBDIRS += runtime.d include ${ROOTPATH}/config.mk