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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [template/] [conv12.C] - Rev 801

Go to most recent revision | Compare with Previous | Blame | View Log

// PR c++/51079

#if __cplusplus > 199711L
struct C1
{
  template <class T>
  operator T() = delete;        // { dg-message "declared here" "" { target c++11 } }
  operator bool() { return false; }
} c1;

int ic1 = c1;                   // { dg-error "deleted" "" { target c++11 } }
int ac1 = c1 + c1;              // { dg-error "deleted" "" { target c++11 } }
#endif

struct C2
{
private:
  template <class T>
  operator T();                 // { dg-error "private" }
public:
  operator bool() { return false; }
} c2;

int ic2 = c2;                   // { dg-error "" }
int ac2 = c2 + c2;              // { dg-error "" }

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

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