langtools/src/share/classes/com/sun/tools/javac/jvm/Code.java
changeset 22443 0922d94d0576
parent 22163 3651128c74eb
child 23966 b9646c1a1666
--- a/langtools/src/share/classes/com/sun/tools/javac/jvm/Code.java	Wed Jan 15 10:57:25 2014 +0100
+++ b/langtools/src/share/classes/com/sun/tools/javac/jvm/Code.java	Wed Jan 15 13:49:57 2014 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -2189,9 +2189,9 @@
         // Keep local variables if
         // 1) we need them for debug information
         // 2) it is an exception type and it contains type annotations
-        if (!varDebugInfo &&
-                (!var.sym.isExceptionParameter() ||
-                var.sym.hasTypeAnnotations())) return;
+        boolean keepLocalVariables = varDebugInfo ||
+            (var.sym.isExceptionParameter() && var.sym.hasTypeAnnotations());
+        if (!keepLocalVariables) return;
         if ((var.sym.flags() & Flags.SYNTHETIC) != 0) return;
         if (varBuffer == null)
             varBuffer = new LocalVar[20];