From c5a0dc3acb2884ff379d86203fb6ba49bca8e4cc Mon Sep 17 00:00:00 2001 From: Egor Ushakov Date: Mon, 21 May 2018 16:06:20 +0300 Subject: [PATCH] more descriptive exception for IDEA-CR-32210 --- .../java/decompiler/modules/decompiler/exps/ExprUtil.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/org/jetbrains/java/decompiler/modules/decompiler/exps/ExprUtil.java b/src/org/jetbrains/java/decompiler/modules/decompiler/exps/ExprUtil.java index 0e6f4a6..302d62f 100644 --- a/src/org/jetbrains/java/decompiler/modules/decompiler/exps/ExprUtil.java +++ b/src/org/jetbrains/java/decompiler/modules/decompiler/exps/ExprUtil.java @@ -26,8 +26,11 @@ public class ExprUtil { if (wrapper != null) { // own class MethodWrapper methodWrapper = wrapper.getMethodWrapper(CodeConstants.INIT_NAME, descriptor); - if (methodWrapper == null && DecompilerContext.getOption(IFernflowerPreferences.IGNORE_INVALID_BYTECODE)) { - return null; + if (methodWrapper == null) { + if (DecompilerContext.getOption(IFernflowerPreferences.IGNORE_INVALID_BYTECODE)) { + return null; + } + throw new RuntimeException("Constructor " + node.classStruct.qualifiedName + "." + CodeConstants.INIT_NAME + descriptor + " not found"); } mask = methodWrapper.synthParameters; }