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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-dev/] [fsf-gcc-snapshot-1-mar-12/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [conversion/] [cond4.C] - Blame information for rev 783

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// Origin: PR c++/45383
2
// { dg-do run }
3
 
4
struct null {
5
    null() {}
6
    template
7
    operator T*() const {
8
    return 0;
9
    }
10
 
11
    template
12
    operator T C::*() const {
13
    return 0;
14
    }
15
private:
16
    null(const null&);
17
    null& operator=(const null&);
18
    void operator&() const;
19
};
20
 
21
static struct null null;
22
 
23
int
24
main()
25
{
26
    int* ptr = null;
27
    if (ptr == null)
28
        return 0;
29
    if (ptr != null)
30
        return 1;
31
}

powered by: WebSVN 2.1.0

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