8sa1-gcc/gcc/testsuite/g++.old-deja/g++.law/cvt19.C

28 lines
338 B
C++
Raw Normal View History

1997-08-19 03:34:40 -04:00
// Build don't link:
// GROUPS passed conversions
// cvt file
// Message-Id: <1166.9307131600@ace.eng.cam.ac.uk>
// From: ajp@eng.cam.ac.uk
// Date: Tue, 13 Jul 93 17:00:44 BST
class B {};
class A {
public:
operator const B*() const {
return b;
}
private:
B* b;
};
main()
{
A a;
if (a!=0) {
}
}