Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-6171

GraalSDK ScriptEngine throws ClassCast instead of returning null

    XMLWordPrintableJSON

Details

    Description

      My code calls

      ScriptEngine eng = ...

      ((Invocable)eng).getInterface(aValue, SomeInterface.class);

      In case of an incompatible 'aValue', the ScriptEngine throws a ClassCastException, although it should return just null (" null if the requested interface is unavailable").

      This behaviour changed after NB 11.3, and is present in NB 12.5 - should be fixed.

      Attachments

        Issue Links

          Activity

            People

              sdedic Svatopluk Dedic
              sdedic Svatopluk Dedic
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 40m
                  40m