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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.old-deja/] [g++.brendan/] [synth1.C] - Blame information for rev 749

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

Line No. Rev Author Line
1 699 jeremybenn
// { dg-do assemble }
2
// { dg-xfail-if "" { sparc64-*-elf } { "*" } { "" } }
3
// { dg-options "-pedantic-errors -g -Wall" }
4
// GROUPS passed synthetics
5
// Check to make sure that g++ doesn't get freaked out about the use
6
// of generated methods that it supposedly "can't see".
7
 
8
class Char {
9
public:
10
    Char();
11
    Char(char v);
12
 
13
    // synthetic copy-constructor and operator=
14
private:
15
    char value;
16
};
17
 
18
class XChar: public Char {
19
public:
20
    XChar();
21
    XChar(char v, int serial);
22
 
23
    void operator=(const XChar& other);
24
private:
25
    int serial;
26
};
27
 
28
void
29
XChar::operator=(const XChar& other)
30
{
31
    Char::operator=(other);
32
    // serial stays the same
33
}

powered by: WebSVN 2.1.0

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