OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.old-deja/] [g++.law/] [ctors17.C] - Blame information for rev 699

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 699 jeremybenn
// { dg-do assemble  }
2
// GROUPS passed constructors
3
// ctor file
4
// Message-Id: <199306151813.gD28471@mail.Germany.EU.net>
5
// From: stephan@ifconnection.de (Stephan Muehlstrasser)
6
// Subject: gcc 2.4.3.1: illegal constructor call not rejected
7
// Date: Tue, 15 Jun 1993 18:34:14 +0200 (MET DST)
8
 
9
// C++0x mode doesn't print the deleted copy constructor as a candidate.
10
// { dg-prune-output ":14:" }
11
 
12
#include 
13
 
14
class X : public std::ifstream {
15
    public:
16
      X(int a, const char *b) {} // { dg-message "note" } candidate
17
};
18
int main()
19
{
20
    X *y = new X(10, "123");
21
    // the compiler must reject this constructor call:
22
    X *x = new X("abc");// { dg-error "match" }
23
    // { dg-message "candidate" "candidate note" { target *-*-* } 22 }
24
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.