mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-27 23:54:52 +08:00
Readd file
From-SVN: r29071
This commit is contained in:
parent
3ebd9bc487
commit
36096ac71b
26
gcc/testsuite/g++.old-deja/g++.other/cond1.C
Normal file
26
gcc/testsuite/g++.old-deja/g++.other/cond1.C
Normal file
@ -0,0 +1,26 @@
|
||||
// Build don't run:
|
||||
// Origin: Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
template <class T>
|
||||
void f (T&) ;
|
||||
|
||||
template <>
|
||||
void f (void (&)())
|
||||
{
|
||||
}
|
||||
|
||||
void g ()
|
||||
{
|
||||
}
|
||||
|
||||
void h ()
|
||||
{
|
||||
}
|
||||
|
||||
bool b;
|
||||
|
||||
int main ()
|
||||
{
|
||||
f (b ? g : h);
|
||||
}
|
||||
|
@ -1,11 +1,26 @@
|
||||
// Build don't link:
|
||||
// Origin: Loring Holden <lsh@cs.brown.edu>
|
||||
// Build don't run:
|
||||
// Origin: Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
class Wpt {};
|
||||
template <class T>
|
||||
void f (T&) ;
|
||||
|
||||
template <>
|
||||
void f (void (&)())
|
||||
{
|
||||
}
|
||||
|
||||
void g ()
|
||||
{
|
||||
}
|
||||
|
||||
void h ()
|
||||
{
|
||||
}
|
||||
|
||||
bool b;
|
||||
|
||||
int main ()
|
||||
{
|
||||
f (b ? g : h);
|
||||
}
|
||||
|
||||
class RAYhit {
|
||||
protected:
|
||||
Wpt _nearpt;
|
||||
public:
|
||||
Wpt surf () const { return true ? Wpt(): _nearpt; }
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user