From 265d8253c9003d02d7e51e594a44ad1e3ee1e201 Mon Sep 17 00:00:00 2001
From: dgelessus <dgelessus@users.noreply.github.com>
Date: Fri, 10 May 2024 15:22:56 +0200
Subject: [PATCH] Make generated Lexer array fields final

---
 src/main/java/org/sablecc/sablecc/lexer/Lexer.java | 4 ++--
 src/main/resources/org/sablecc/sablecc/lexer.txt   | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/main/java/org/sablecc/sablecc/lexer/Lexer.java b/src/main/java/org/sablecc/sablecc/lexer/Lexer.java
index 2d529b1..d5a7e59 100644
--- a/src/main/java/org/sablecc/sablecc/lexer/Lexer.java
+++ b/src/main/java/org/sablecc/sablecc/lexer/Lexer.java
@@ -621,7 +621,7 @@ public class Lexer
         return this.text.substring(0, acceptLength);
     }
 
-    private static int[][][][] gotoTable;
+    private static final int[][][][] gotoTable;
 /*  {
         { // NORMAL
             {{9, 9, 1}, {10, 10, 2}, {13, 13, 3}, {32, 32, 4}, {39, 39, 5}, {40, 40, 6}, {41, 41, 7}, {42, 42, 8}, {43, 43, 9}, {44, 44, 10}, {45, 45, 11}, {46, 46, 12}, {47, 47, 13}, {48, 48, 14}, {49, 57, 15}, {58, 58, 16}, {59, 59, 17}, {61, 61, 18}, {63, 63, 19}, {65, 65, 20}, {72, 72, 21}, {73, 73, 22}, {78, 78, 23}, {80, 80, 24}, {83, 83, 25}, {84, 84, 26}, {91, 91, 27}, {93, 93, 28}, {97, 122, 29}, {123, 123, 30}, {124, 124, 31}, {125, 125, 32}, },
@@ -873,7 +873,7 @@ public class Lexer
         }
     };*/
 
-    private static int[][] accept;
+    private static final int[][] accept;
 /*  {
         // NORMAL
         {-1, 38, 38, 38, 38, -1, 20, 21, 27, 24, 29, 25, 14, 30, 35, 35, 32, 16, 17, 26, -1, -1, -1, -1, 13, -1, 12, 18, 19, 33, 22, 28, 23, 38, -1, -1, 31, 15, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 33, -1, 33, -1, 34, 34, -1, -1, -1, 39, 39, 36, -1, -1, -1, 10, -1, -1, -1, -1, -1, -1, -1, 33, 37, -1, 39, 39, -1, -1, -1, 11, -1, -1, -1, -1, -1, 9, 33, 33, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 2, 8, 4, -1, 3, 5, 1, -1, 7, -1, -1, -1, 6, },
diff --git a/src/main/resources/org/sablecc/sablecc/lexer.txt b/src/main/resources/org/sablecc/sablecc/lexer.txt
index c449448..3b52417 100644
--- a/src/main/resources/org/sablecc/sablecc/lexer.txt
+++ b/src/main/resources/org/sablecc/sablecc/lexer.txt
@@ -320,7 +320,7 @@ Macro:LexerBody
         return this.text.substring(0, acceptLength);
     }
 
-    private static int[][][][] gotoTable;
+    private static final int[][][][] gotoTable;
 /*  {
 
 $
@@ -328,7 +328,7 @@ $
 Macro:LexerAcceptHeader
     };*/
 
-    private static int[][] accept;
+    private static final int[][] accept;
 /*  {
 
 $
-- 
GitLab