summaryrefslogtreecommitdiffstats
path: root/test/CXX/basic/basic.lookup/basic.lookup.unqual/p15.cpp
blob: cebc3e99d09fa03d56d1ea81e8755d71bcd2f2c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// RUN: clang-cc -fsyntax-only -verify %s
// XFAIL: *

class C {
public:
  C(int a, int b);
};

C::C(int a, // expected-note {{previous definition}}
     int b) // expected-note {{previous definition}}
try {
  int c;

} catch (int a) { // expected-error {{redefinition of 'a'}}
  int b; // expected-error {{redefinition of 'b'}}
  ++c; // expected-error {{use of undeclared identifion 'c'}}
}
OpenPOWER on IntegriCloud