Fix rawtypes and fallthrough warnings in FST suggester; "all" does not work with JavaC

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1412614 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Uwe Schindler 2012-11-22 16:41:17 +00:00
parent e714ff0bc3
commit 5a91c157b6
2 changed files with 3 additions and 2 deletions

View File

@ -109,7 +109,7 @@ public class FSTCompletion {
* Find and push an exact match to the first position of the result
* list if found.
*/
@SuppressWarnings("unchecked")
@SuppressWarnings({"unchecked","rawtypes"})
public FSTCompletion(FST<Object> automaton, boolean higherWeightsFirst, boolean exactFirst) {
this.automaton = automaton;
if (automaton != null) {
@ -133,7 +133,7 @@ public class FSTCompletion {
* Cache the root node's output arcs starting with completions with the
* highest weights.
*/
@SuppressWarnings({"all"})
@SuppressWarnings({"unchecked","rawtypes"})
private static Arc<Object>[] cacheRootArcs(FST<Object> automaton) {
try {
List<Arc<Object>> rootArcs = new ArrayList<Arc<Object>>();

View File

@ -822,6 +822,7 @@ public class FuzzySuggesterTest extends LuceneTestCase {
assertEquals("[barbazfoo/10]", suggester.lookup("bar baz foo", false, 5).toString());
}
@SuppressWarnings("fallthrough")
private static String addRandomEdit(String string, int prefixLength) {
char[] input = string.toCharArray();
StringBuilder builder = new StringBuilder();