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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [pr45330.C] - Blame information for rev 724

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

Line No. Rev Author Line
1 693 jeremybenn
// { dg-do compile }
2
// Search std, __cxxabiv1, and global namespaces, plus one more.
3
// { dg-options "--param cxx-max-namespaces-for-diagnostic-help=4" }
4
 
5
#define NSPACE(NAME) namespace NAME { int foo; }
6
 
7
namespace A
8
{
9
  int foo;                      // { dg-message "A::foo" "suggested alternative" }
10
}
11
 
12
namespace B
13
{
14
  int foo;
15
}
16
 
17
namespace C
18
{
19
  int foo;
20
}
21
 
22
namespace D
23
{
24
  int foo;
25
}
26
 
27
namespace E
28
{
29
  int foo;
30
}
31
 
32
int bar()
33
{
34
  return foo;                   // { dg-error "was not declared" }
35
  // { dg-message "maximum limit of 4 namespaces" "maximum limit" { target *-*-* } 34 }
36
  // { dg-message "suggested alternative" "suggested alternative" { target *-*-* } 34 }
37
}

powered by: WebSVN 2.1.0

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