You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by GitBox <gi...@apache.org> on 2021/06/07 14:36:41 UTC

[GitHub] [solr] madrob commented on a change in pull request #165: SOLR-15385 RawTypes Part II, Searching for NamedList

madrob commented on a change in pull request #165:
URL: https://github.com/apache/solr/pull/165#discussion_r646648410



##########
File path: solr/core/src/java/org/apache/solr/api/ApiBag.java
##########
@@ -301,19 +301,18 @@ public static SpecProvider constructSpec(PluginInfo info) {
     Object specObj = info == null ? null : info.attributes.get("spec");
     if (specObj == null) specObj = "emptySpec";
     if (specObj instanceof Map) {
-      @SuppressWarnings({"rawtypes"})
-      Map map = (Map) specObj;
+        assert false : "got a map from a string";

Review comment:
       info.attributes is a Map<String,String> so we should never be getting a specObj that is a Map. However, the code exists and I don't necessarily trust out type safety everywhere, so I wanted to give our tests a chance to prove me wrong.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org