Fix expected enum value printing (underlying type).

This commit is contained in:
Axel Naumann 2016-02-04 18:02:36 +01:00 committed by sftnight
parent c2172523f4
commit a8dcd932fe
3 changed files with 11 additions and 7 deletions

View File

@ -30,8 +30,12 @@ gCling->process("\"Root\"", &V);
V
// CHECK: (cling::Value &) boxes [(const char [5]) "Root"]
// End PR #98146
typedef enum {k1,k2} enumName;
enumName var
// CHECK: (enumName) (::k1) : (int) 0
.rawInput 1
typedef enum {k1 = 0, k2} enumName;
enumName var = k1;
.rawInput 0
var
// CHECK: (enumName) (::k1) : ({{(unsigned )?}}int) 0
const enumName constVar = (enumName) 1 // k2 is invisible!
// CHECK: (const enumName) (::k2) : (int) 1
// CHECK: (const enumName) (::k2) : ({{(unsigned )?}}int) 1

View File

@ -14,6 +14,6 @@ template<> struct F<0> {
enum {RET = 1};
};
F<7>::RET
//CHECK: (F<7>::(anonymous)) (F<7>::::RET) : (int) 5040
//CHECK: (F<7>::(anonymous)) (F<7>::::RET) : ({{(unsigned )?}}int) 5040
.q

View File

@ -17,7 +17,7 @@ std::make_pair("s",10)
//CHECK: (std::pair<{{.+char.+\[2\].*,.*int.*}}>) { "s", 10 }
std::make_pair(4L,'c')
//CHECK: (std::pair<{{.*long.*,char.*}}>) { 4, 'c' }
//CHECK: (std::pair<{{.*long.*,.*char.*}}>) { 4, 'c' }
std::make_tuple()
//CHECK: (std::tuple<>) { }
@ -29,6 +29,6 @@ std::make_tuple(1.2f)
//CHECK: (std::tuple<{{.*float.*}}>) { 1.20000f }
std::make_tuple(1, std::make_tuple(1, 'c'))
//CHECK: (std::tuple<{{.*int,.*std::tuple<.*int,.*char.*>.*}}>) { 1, { 1, 'c' } }
//CHECK: (std::tuple<{{.*int.*,.*std::tuple<.*int,.*char.*>.*}}>) { 1, { 1, 'c' } }
.q