From f1f376d24803a3ebffdc64721c75999fceb48067 Mon Sep 17 00:00:00 2001 From: Andreas Dangel Date: Thu, 25 Jul 2024 12:23:04 +0200 Subject: [PATCH] Deprecate generated parser implementations --- docs/pages/release_notes.md | 9 +++++++++ pmd-jsp/etc/grammar/Jsp.jjt | 3 +++ pmd-plsql/etc/grammar/PLSQL.jjt | 2 +- pmd-velocity/etc/grammar/Vtl.jjt | 5 ++++- pmd-visualforce/etc/grammar/Vf.jjt | 5 +++++ 5 files changed, 22 insertions(+), 2 deletions(-) diff --git a/docs/pages/release_notes.md b/docs/pages/release_notes.md index bc1a36ec7a..bbef7173be 100644 --- a/docs/pages/release_notes.md +++ b/docs/pages/release_notes.md @@ -17,6 +17,15 @@ This is a {{ site.pmd.release_type }} release. ### 🐛 Fixed Issues ### 🚨 API Changes +* pmd-jsp + * {%jdoc jsp::lang.jsp.ast.JspParserImpl %} is deprecated now. It should have been package-private + because this is an implementation class that should not be used directly. +* pmd-velocity + * {%jdoc velocity::lang.velocity.ast.VtlParserImpl %} is deprecated now. It should have been package-private + because this is an implementation class that should not be used directly. +* pmd-visualforce + * {%jdoc visualforce::lang.visualforce.ast.VfParserImpl %} is deprecated now. It should have been package-private + because this is an implementation class that should not be used directly. ### ✨ External Contributions diff --git a/pmd-jsp/etc/grammar/Jsp.jjt b/pmd-jsp/etc/grammar/Jsp.jjt index 1f74b3dcf7..c87cb23aae 100644 --- a/pmd-jsp/etc/grammar/Jsp.jjt +++ b/pmd-jsp/etc/grammar/Jsp.jjt @@ -33,7 +33,10 @@ package net.sourceforge.pmd.lang.jsp.ast; /** * JSP Parser for PMD. * @author Pieter, Application Engineers NV/SA, http://www.ae.be + * @deprecated Since 7.5.0. JspParserImpl should have been package private because this is an implementation class + * that should not be used directly. */ +@Deprecated public class JspParserImpl { diff --git a/pmd-plsql/etc/grammar/PLSQL.jjt b/pmd-plsql/etc/grammar/PLSQL.jjt index c9f2f4b0d9..81224d0402 100644 --- a/pmd-plsql/etc/grammar/PLSQL.jjt +++ b/pmd-plsql/etc/grammar/PLSQL.jjt @@ -176,7 +176,7 @@ import java.util.ArrayList; import java.util.List; /** - * @deprecated PLSQLParserImpl should have been package private because this is an implementation class + * @deprecated Since 7.3.0. PLSQLParserImpl should have been package private because this is an implementation class * that should not be used directly. */ @Deprecated diff --git a/pmd-velocity/etc/grammar/Vtl.jjt b/pmd-velocity/etc/grammar/Vtl.jjt index 74804d4dd0..3c9cbb533a 100644 --- a/pmd-velocity/etc/grammar/Vtl.jjt +++ b/pmd-velocity/etc/grammar/Vtl.jjt @@ -58,7 +58,10 @@ import net.sourceforge.pmd.lang.ast.impl.javacc.JavaccToken; * @author Geir Magnusson Jr. * @author Henning P. Schmiedehausen * @version $Id$ -*/ + * @deprecated Since 7.5.0. VtlParserImpl should have been package private because this is an implementation class + * that should not be used directly. + */ +@Deprecated public class VtlParserImpl { private void throwParseException(String message) { diff --git a/pmd-visualforce/etc/grammar/Vf.jjt b/pmd-visualforce/etc/grammar/Vf.jjt index 6fa854e7c3..81c31b2df7 100644 --- a/pmd-visualforce/etc/grammar/Vf.jjt +++ b/pmd-visualforce/etc/grammar/Vf.jjt @@ -13,6 +13,11 @@ options { PARSER_BEGIN(VfParserImpl) package net.sourceforge.pmd.lang.visualforce.ast; +/** + * @deprecated Since 7.5.0. VfParserImpl should have been package private because this is an implementation class + * that should not be used directly. + */ +@Deprecated public class VfParserImpl {