Lines Matching refs:pointer_wrappers

237 namespace pointer_wrappers {  namespace
262 template <> struct simplify_type<pointer_wrappers::PTy> {
263 typedef pointer_wrappers::Base *SimpleType;
264 static SimpleType getSimplifiedValue(pointer_wrappers::PTy &P) { in getSimplifiedValue()
268 template <> struct simplify_type<const pointer_wrappers::PTy> {
269 typedef pointer_wrappers::Base *SimpleType;
270 static SimpleType getSimplifiedValue(const pointer_wrappers::PTy &P) { in getSimplifiedValue()
278 namespace pointer_wrappers { namespace
281 pointer_wrappers::Base B;
282 pointer_wrappers::Derived D;
285 pointer_wrappers::PTy MN(nullptr);
286 pointer_wrappers::PTy MB(&B);
287 pointer_wrappers::PTy MD(&D);
290 const pointer_wrappers::PTy CN(nullptr);
291 const pointer_wrappers::PTy CB(&B);
292 const pointer_wrappers::PTy CD(&D);
295 EXPECT_TRUE(!isa<pointer_wrappers::Derived>(MB)); in TEST()
296 EXPECT_TRUE(!isa<pointer_wrappers::Derived>(CB)); in TEST()
297 EXPECT_TRUE(isa<pointer_wrappers::Derived>(MD)); in TEST()
298 EXPECT_TRUE(isa<pointer_wrappers::Derived>(CD)); in TEST()
302 EXPECT_TRUE(cast<pointer_wrappers::Derived>(MD) == &D); in TEST()
303 EXPECT_TRUE(cast<pointer_wrappers::Derived>(CD) == &D); in TEST()
307 EXPECT_TRUE(cast_or_null<pointer_wrappers::Derived>(MN) == nullptr); in TEST()
308 EXPECT_TRUE(cast_or_null<pointer_wrappers::Derived>(CN) == nullptr); in TEST()
309 EXPECT_TRUE(cast_or_null<pointer_wrappers::Derived>(MD) == &D); in TEST()
310 EXPECT_TRUE(cast_or_null<pointer_wrappers::Derived>(CD) == &D); in TEST()
314 EXPECT_TRUE(dyn_cast<pointer_wrappers::Derived>(MB) == nullptr); in TEST()
315 EXPECT_TRUE(dyn_cast<pointer_wrappers::Derived>(CB) == nullptr); in TEST()
316 EXPECT_TRUE(dyn_cast<pointer_wrappers::Derived>(MD) == &D); in TEST()
317 EXPECT_TRUE(dyn_cast<pointer_wrappers::Derived>(CD) == &D); in TEST()
321 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(MN) == nullptr); in TEST()
322 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(CN) == nullptr); in TEST()
323 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(MB) == nullptr); in TEST()
324 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(CB) == nullptr); in TEST()
325 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(MD) == &D); in TEST()
326 EXPECT_TRUE(dyn_cast_or_null<pointer_wrappers::Derived>(CD) == &D); in TEST()