Community
Participate
Working Groups
try a int[]; a.getSize(); onexception(e NullValueException) syslib.writestderr(e.message); end The code does not go into the onexception block because it's not an EGL exception - instead it's a core NPE. The generated code is: a.getSize(); In RBD we would wrap anything on a reference type with egl.checkNull() so that our own exception type would be thrown (and therefore caught).
Justin, After the recent language changes, I think this would probably work as-is; a can never be null. However, there is still an issue here because if a is nullable, then the RT null check should be generated....
Yes, the declaration should now be "a aint[]?;" to cause this problem.
Fixed; the array type template wasn't respecting / enforcing nullable.
Verified