View | Details | Raw Unified | Return to bug 129317 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/jdt/core/tests/model/AttachSourceTests.java (+14 lines)
Lines 84-89 Link Here
84
		"  <K, V> V foo(K key, V value) {\n" +
84
		"  <K, V> V foo(K key, V value) {\n" +
85
		"    return value;\n" +
85
		"    return value;\n" +
86
		"  }\n" +
86
		"  }\n" +
87
		"  void foo(int i, X<Object[]> x) {\n" +
88
		"  }\n" +
87
		"}"
89
		"}"
88
	};
90
	};
89
	IJavaProject project = getJavaProject("AttachSourceTests");
91
	IJavaProject project = getJavaProject("AttachSourceTests");
Lines 327-332 Link Here
327
		"  }",
329
		"  }",
328
		method.getSource());
330
		method.getSource());
329
}
331
}
332
/*
333
 * Ensures that the source of a generic method can be retrieved.
334
 * (regression test for bug 129317 Outline view inconsistent with code
335
 */
336
public void testGeneric3() throws JavaModelException {
337
	IMethod method = this.genericType.getMethod("foo", new String[] {"I", "Lgeneric.X<[Ljava.lang.Object;>;"});
338
	assertSourceEquals(
339
		"Unexpected source",
340
		"void foo(int i, X<Object[]> x) {\n" + 
341
		"  }",
342
		method.getSource());
343
}
330
/**
344
/**
331
 * Ensures that name ranges exists for BinaryMembers that have
345
 * Ensures that name ranges exists for BinaryMembers that have
332
 * mapped source.
346
 * mapped source.
(-)model/org/eclipse/jdt/internal/core/SourceMapper.java (+3 lines)
Lines 1096-1101 Link Here
1096
							unqualifiedName.append(current);
1096
							unqualifiedName.append(current);
1097
							sigStart = true;
1097
							sigStart = true;
1098
							break;
1098
							break;
1099
						case Signature.C_ARRAY :
1100
							unqualifiedName.append(current);
1101
							break;
1099
						default:
1102
						default:
1100
							if (sigStart) {
1103
							if (sigStart) {
1101
								switch(current) {
1104
								switch(current) {
(-)model/org/eclipse/jdt/core/Signature.java (+3 lines)
Lines 1984-1989 Link Here
1984
					argumentStart = i+1;					
1984
					argumentStart = i+1;					
1985
				}
1985
				}
1986
				break;
1986
				break;
1987
			case '[' :
1988
				buffer.append('[');
1989
				break;
1987
		}
1990
		}
1988
	}
1991
	}
1989
	buffer.append('>');
1992
	buffer.append('>');

Return to bug 129317