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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [g++.old-deja/] [g++.law/] [cvt18.C] - Rev 305

Compare with Previous | Blame | View Log

// { dg-do assemble  }
// GROUPS passed conversions
// cvt file
// Message-Id: <9307090042.AA28565@uluru.Stanford.EDU>
// From: interran@uluru.stanford.edu (John Interrante)
// Subject: gcc 2.4.5 on sparc-sun-sunos4.1.2: automatic conversion functions
// Date: Thu, 8 Jul 93 17:42:12 PDT

class Token {
public:
    operator const void*() const;
    int operator !=(int code) const;
private:
    int code_;
};

extern Token next_token();

void foo(Token token) {
    if (token && token != '{') {}

    const int inside_body = 1;
    if (inside_body && (token = next_token())) {}
}

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.