зеркало из https://github.com/mozilla/gecko-dev.git
Changing Kit.initCause to take and return RuntimeException: this is how it is supposed to be used, that is wrap checkable exceptions into uncheckable RuntimeExceptions.
This commit is contained in:
Родитель
0f600362d0
Коммит
8899a6261b
|
@ -112,7 +112,8 @@ public class Kit
|
||||||
* <tt>ex.initCause(cause)</tt> or otherwise do nothing.
|
* <tt>ex.initCause(cause)</tt> or otherwise do nothing.
|
||||||
* @return The <tt>ex</tt> argument.
|
* @return The <tt>ex</tt> argument.
|
||||||
*/
|
*/
|
||||||
public static Throwable initCause(Throwable ex, Throwable cause)
|
public static RuntimeException initCause(RuntimeException ex,
|
||||||
|
Throwable cause)
|
||||||
{
|
{
|
||||||
if (Throwable_initCause != null) {
|
if (Throwable_initCause != null) {
|
||||||
Object[] args = { cause };
|
Object[] args = { cause };
|
||||||
|
|
Загрузка…
Ссылка в новой задаче