|
Lines 1-5
Link Here
|
| 1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
| 2 |
* Copyright (c) 2000, 2012 IBM Corporation and others. |
2 |
* Copyright (c) 2000, 2013 IBM Corporation and others. |
| 3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
| 4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
| 5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
|
Lines 2750-2753
Link Here
|
| 2750 |
}); |
2750 |
}); |
| 2751 |
} |
2751 |
} |
| 2752 |
|
2752 |
|
|
|
2753 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=397888 |
| 2754 |
public void test397888a() { |
| 2755 |
Map customOptions = getCompilerOptions(); |
| 2756 |
customOptions.put(JavaCore.COMPILER_DOC_COMMENT_SUPPORT, JavaCore.ENABLED); |
| 2757 |
customOptions.put(CompilerOptions.OPTION_ReportUnusedTypeParameter, CompilerOptions.ERROR); |
| 2758 |
customOptions.put(CompilerOptions.OPTION_ReportUnusedParameterIncludeDocCommentReference, |
| 2759 |
CompilerOptions.ENABLED); |
| 2760 |
|
| 2761 |
this.runConformTest(new String[] { |
| 2762 |
"X.java", |
| 2763 |
"public class X {\n"+ |
| 2764 |
"/***" + |
| 2765 |
" * @param S" + |
| 2766 |
" * @param t" + |
| 2767 |
" * @param k" + |
| 2768 |
" */" + |
| 2769 |
"public <S> void ph(int t) {\n"+ |
| 2770 |
"}\n"+ |
| 2771 |
"}\n" |
| 2772 |
}, |
| 2773 |
null /* no expected output string */, |
| 2774 |
null /* no extra class libraries */, |
| 2775 |
true /* flush output directory */, |
| 2776 |
null /* no vm arguments */, |
| 2777 |
customOptions, |
| 2778 |
null /* no custom requestor*/, |
| 2779 |
false /* do not skip javac for this peculiar test */); |
| 2780 |
} |
| 2781 |
|
| 2782 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=397888 |
| 2783 |
public void test397888b() { |
| 2784 |
Map customOptions = getCompilerOptions(); |
| 2785 |
customOptions.put(JavaCore.COMPILER_DOC_COMMENT_SUPPORT, JavaCore.ENABLED); |
| 2786 |
customOptions.put(CompilerOptions.OPTION_ReportUnusedTypeParameter, CompilerOptions.ERROR); |
| 2787 |
customOptions.put(CompilerOptions.OPTION_ReportUnusedParameterIncludeDocCommentReference, |
| 2788 |
CompilerOptions.DISABLED); |
| 2789 |
|
| 2790 |
this.runNegativeTest( |
| 2791 |
new String[] { |
| 2792 |
"X.java", |
| 2793 |
"public class X {\n"+ |
| 2794 |
"/***" + |
| 2795 |
" * @param S" + |
| 2796 |
" * @param t" + |
| 2797 |
" * @param k" + |
| 2798 |
" */" + |
| 2799 |
"public <S> void ph(int t) {\n"+ |
| 2800 |
"}\n"+ |
| 2801 |
"}\n" |
| 2802 |
}, |
| 2803 |
"----------\n" + |
| 2804 |
"1. ERROR in X.java (at line 2)\n" + |
| 2805 |
" /*** * @param S * @param t * @param k */public <S> void ph(int t) {\n" + |
| 2806 |
" ^\n" + |
| 2807 |
"Unused type parameter S\n" + |
| 2808 |
"----------\n", |
| 2809 |
null, true, customOptions); |
| 2810 |
} |
| 2753 |
} |
2811 |
} |