diff --git a/src/core/lombok/eclipse/handlers/HandleConstructor.java b/src/core/lombok/eclipse/handlers/HandleConstructor.java index 81b4cf1194..1941569670 100755 --- a/src/core/lombok/eclipse/handlers/HandleConstructor.java +++ b/src/core/lombok/eclipse/handlers/HandleConstructor.java @@ -588,25 +588,27 @@ public MethodDeclaration createStaticConstructor(AccessLevel level, String name, } private void generateConstructorJavadoc(EclipseNode typeNode, EclipseNode constructorNode, Collection fields) { - if (fields.isEmpty()) return; - - String constructorJavadoc = getConstructorJavadocHeader(typeNode.getName()); - boolean fieldDescriptionAdded = false; - for (EclipseNode fieldNode : fields) { - String paramName = String.valueOf(removePrefixFromField(fieldNode)); - String fieldJavadoc = getDocComment(fieldNode); - String paramJavadoc = getConstructorParameterJavadoc(paramName, fieldJavadoc); - - if (paramJavadoc == null) { - paramJavadoc = "@param " + paramName; - } else { - fieldDescriptionAdded = true; + try { + if (fields.isEmpty()) return; + + String constructorJavadoc = getConstructorJavadocHeader(typeNode.getName()); + boolean fieldDescriptionAdded = false; + for (EclipseNode fieldNode : fields) { + String paramName = String.valueOf(removePrefixFromField(fieldNode)); + String fieldJavadoc = getDocComment(fieldNode); + String paramJavadoc = getConstructorParameterJavadoc(paramName, fieldJavadoc); + + if (paramJavadoc == null) { + paramJavadoc = "@param " + paramName; + } else { + fieldDescriptionAdded = true; + } + + constructorJavadoc = addJavadocLine(constructorJavadoc, paramJavadoc); } - - constructorJavadoc = addJavadocLine(constructorJavadoc, paramJavadoc); - } - if (fieldDescriptionAdded) { - setDocComment(typeNode, constructorNode, constructorJavadoc); - } + if (fieldDescriptionAdded) { + setDocComment(typeNode, constructorNode, constructorJavadoc); + } + } catch (Exception ignore) {} } }