blob: 70a1f6d537fbfaaac648e56de2b00c3ccd92e19e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
|
/*******************************************************************************
* Copyright (c) 2013, 2014 Google, Inc and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Sergey Prigogin (Google) - initial API and implementation
*******************************************************************************/
package org.eclipse.cdt.internal.index.tests;
import junit.framework.TestSuite;
/**
* Index tests involving multiple header and source files.
*
* The first line of each comment section preceding a test contains the name of the file
* to put the contents of the section to. To request the AST of a file, put an asterisk after
* the file name.
*/
public class IndexMultiFileTest extends IndexBindingResolutionTestBase {
public IndexMultiFileTest() {
setStrategy(new SinglePDOMTestNamedFilesStrategy(true));
}
public static TestSuite suite() {
return suite(IndexMultiFileTest.class);
}
// A.h
// template <typename T>
// struct A {
// void m(T p);
// };
// B.h
// struct B {};
// confuser.cpp
// #include "A.h"
//
// namespace {
// struct B {};
// }
// A<B*> z;
// test.cpp *
// #include "A.h"
// #include "B.h"
//
// void test(A<B*> a, B* b) {
// a.m(b);
// }
public void testAnonymousNamespace_416278() throws Exception {
checkBindings();
}
// a.h
// namespace ns1 {
// }
//
// namespace ns2 {
// namespace ns3 {
// namespace waldo = ns1;
// }
// }
// a.cpp
// #include "a.h"
// b.h
// namespace ns1 {
// }
//
// namespace ns2 {
// namespace waldo = ns1;
// }
// b.cpp
// #include "b.h"
//
// namespace ns2 {
// namespace waldo = ::ns1;
// }
// c.cpp
// namespace ns1 {
// class A {};
// }
//
// namespace waldo = ns1;
//
// namespace ns2 {
// namespace ns3 {
// waldo::A a;
// }
// }
public void testNamespaceAlias_442117() throws Exception {
checkBindings();
}
}
|