This is an automated email from the ASF dual-hosted git repository.

joshtynjala pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-compiler.git

commit 2560226fcf36a96b19b23a122724f979018e3055
Author: Josh Tynjala <joshtynj...@apache.org>
AuthorDate: Wed Apr 24 09:47:23 2024 -0700

    CSS.g: require EOF so that extra invalid content at the end after valid 
content is not ignored silently
---
 RELEASE_NOTES.md                                                       | 1 +
 compiler/src/main/antlr3/org/apache/royale/compiler/internal/css/CSS.g | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index b3b891157..f2727c1a9 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -26,6 +26,7 @@ Apache Royale Compiler 0.9.11
 - compiler: Fix non-string values in an MXML array sometimes getting 
incorrectly wrapped in quotes when emitting JavaScript.
 - compiler: Fix null exception for `<fx:Style>` tags that contain only 
comments.
 - compiler: Fix exceptions for `<fx:Style>` tags that contain invalid CSS.
+- compiler: Fix silently ignoring errors in some invalid CSS content, if it 
appears at the end after valid content.
 - compiler: Fix crash when attempting to use `--remove-circulars=false` with a 
release build.
 - debugger: Fix exception when evaluating certain expressions at run-time.
 - formatter: Added `insert-new-line-else` configuration option.
diff --git 
a/compiler/src/main/antlr3/org/apache/royale/compiler/internal/css/CSS.g 
b/compiler/src/main/antlr3/org/apache/royale/compiler/internal/css/CSS.g
index 28bdf8887..838563d77 100644
--- a/compiler/src/main/antlr3/org/apache/royale/compiler/internal/css/CSS.g
+++ b/compiler/src/main/antlr3/org/apache/royale/compiler/internal/css/CSS.g
@@ -191,7 +191,7 @@ private final int endOfSimpleSelector()
  * Root rule for a CSS file.
  */
 stylesheet
-    :   ( namespaceStatement | fontFace | keyframes | mediaQuery | ruleset )*
+    :   ( namespaceStatement | fontFace | keyframes | mediaQuery | ruleset )* 
EOF
     ;
 
 /**

Reply via email to