Recommended solutions based on your search

Samebug tips

This happens when you try to instantiate a class that can't be instantiated, either because the class object is abstract, an interface, an array class, a primitive type, void, or because the class has no nullary constructor.

java.lang.InstantiationException: Main$BadThrow at java.lang.Class.newInstance0(Class.java:291) at java.lang.Class.newInstance(Class.java:259) at undefined.Main.foo(Main.java:27) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at undefined.Main.main(Main.java:17)

Users with the same issue

Unknown user

Once, 3 weeks ago

Unknown user

Once, 1 year ago

Unknown user

Once, 1 year ago

Unknown user

Once, 1 year ago

Unknown user

Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.