From 911610e1f740ff36a8a3075850d738f8e29efa35 Mon Sep 17 00:00:00 2001 From: Georgios Andrianakis Date: Sun, 12 Sep 2021 12:37:05 +0300 Subject: [PATCH] Mark the auto-generated RESTEasy constructor as synthetic This is mainly done in order to allow code coverage tools to skip the constructor Relates to: #18559 --- .../common/deployment/ResteasyServerCommonProcessor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extensions/resteasy-classic/resteasy-server-common/deployment/src/main/java/io/quarkus/resteasy/server/common/deployment/ResteasyServerCommonProcessor.java b/extensions/resteasy-classic/resteasy-server-common/deployment/src/main/java/io/quarkus/resteasy/server/common/deployment/ResteasyServerCommonProcessor.java index f8bc8f674c319..7eb5e8ae332cf 100755 --- a/extensions/resteasy-classic/resteasy-server-common/deployment/src/main/java/io/quarkus/resteasy/server/common/deployment/ResteasyServerCommonProcessor.java +++ b/extensions/resteasy-classic/resteasy-server-common/deployment/src/main/java/io/quarkus/resteasy/server/common/deployment/ResteasyServerCommonProcessor.java @@ -693,7 +693,8 @@ public ClassVisitor apply(String className, ClassVisitor classVisitor) { public void visit(int version, int access, String name, String signature, String superName, String[] interfaces) { super.visit(version, access, name, signature, superName, interfaces); - MethodVisitor ctor = visitMethod(Modifier.PUBLIC, "", "()V", null, + MethodVisitor ctor = visitMethod(Opcodes.ACC_PUBLIC | Opcodes.ACC_SYNTHETIC, "", + "()V", null, null); ctor.visitCode(); ctor.visitVarInsn(Opcodes.ALOAD, 0);