You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/** * A version of "sneaky throw" to relay exceptions */staticvoidrethrow(finalThrowableex) {
if (ex != null) {
if (exinstanceofError)
throw (Error)ex;
if (exinstanceofRuntimeException)
throw (RuntimeException)ex;
ForkJoinTask.<RuntimeException>uncheckedThrow(ex);
}
}
/** * The sneaky part of sneaky throw, relying on generics * limitations to evade compiler complaints about rethrowing * unchecked exceptions */@SuppressWarnings("unchecked") static <TextendsThrowable>
voiduncheckedThrow(Throwablet) throwsT {
if (t != null)
throw (T)t; // rely on vacuous cast
}
The text was updated successfully, but these errors were encountered:
The throwException method doesn't exist on sun.misc.Unsafe on Android,
but good news, it can be emulated in Java without any performance loss.
From jsr116y: http://gee.cs.oswego.edu/cgi-bin/viewcvs.cgi/jsr166/src/jsr166e/ForkJoinTask.java?view=markup
The text was updated successfully, but these errors were encountered: