repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
2018-01-24 Richard Biener <rguenther@suse.de>
[official-gcc.git]
/
gcc
/
testsuite
/
obj-c++.dg
/
method-namespace-1.mm
blob
6095f572ccacdf4dfe25cc22fd86a718ebc25a76
1
/* Test for usage of namespace inside @implementation. */
2
/* { dg-do compile } */
3
@interface MyDocument
4
@end
5
6
@implementation MyDocument
7
8
// This deprecated usage works
9
static void foo1() { }
10
11
// This preferred usage does _not_ work
12
namespace
13
{
14
void foo2() { }
15
}
16
17
namespace STD
18
{
19
void foo3 () {}
20
}
21
22
using namespace STD;
23
24
- (void) GARF {
25
foo2();
26
foo3();
27
}
28
29
@end