From 3ee6981264ae6f9019dabf25e80f42e8b37ee6f6 Mon Sep 17 00:00:00 2001 From: sebthom Date: Thu, 12 May 2022 15:08:08 +0200 Subject: [PATCH] Suppress instanceof compiler warnings Suppresses "X is a raw type. References to generic type X should be parameterized." --- .../tm4e/core/internal/parser/PListContentHandler.java | 2 +- .../eclipse/tm4e/core/internal/parser/PListParserYAML.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListContentHandler.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListContentHandler.java index c33895a59..9911d027c 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListContentHandler.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListContentHandler.java @@ -94,7 +94,7 @@ private final class PListObject { this.values = values; } - @SuppressWarnings("unchecked") + @SuppressWarnings({ "rawtypes", "unchecked" }) void addValue(final Object value) { if (values instanceof PropertySettable propertySettable) { propertySettable.setProperty(path.last(), value); diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListParserYAML.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListParserYAML.java index 9ff88c89a..a750a1fc4 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListParserYAML.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/PListParserYAML.java @@ -34,7 +34,7 @@ public PListParserYAML(final PropertySettable.Factory objectFactory) this.objectFactory = objectFactory; } - @SuppressWarnings("unchecked") + @SuppressWarnings({ "rawtypes", "unchecked" }) private void addListToPList(final PListContentHandler pList, final List list) throws SAXException { pList.startElement(null, "array", null, null); @@ -51,7 +51,7 @@ private void addListToPList(final PListContentHandler pList, final List pList, final Map map) throws SAXException { pList.startElement(null, "dict", null, null);