Apache Lucene open-source search software
Upgrade snowball to 2d2e312df56f2ede014a4ffb3e91e6dea43c24be (#15505)
Justas Sakalauskasb26f76729812
diff --git a/build-tools/build-infra/src/main/java/org/apache/lucene/gradle/plugins/licenses/CheckLicensesTask.java b/build-tools/build-infra/src/main/java/org/apache/lucene/gradle/plugins/licenses/CheckLicensesTask.javaindex 77c928e67c3..8b06ce040ab 100644--- a/build-tools/build-infra/src/main/java/org/apache/lucene/gradle/plugins/licenses/CheckLicensesTask.java+++ b/build-tools/build-infra/src/main/java/org/apache/lucene/gradle/plugins/licenses/CheckLicensesTask.java@@ -99,7 +99,7 @@ public abstract class CheckLicensesTask extends DefaultTask {"Generated files",fixedSubstrings(// snowball- "Generated by Snowball",+ ".sbl by Snowball",// javacc"Generated By:JavaCC")));diff --git a/gradle/regenerate/snowball/snowball.sh b/gradle/regenerate/snowball/snowball.shindex d95ca53b1ea..a5ccb04a639 100644--- a/gradle/regenerate/snowball/snowball.sh+++ b/gradle/regenerate/snowball/snowball.sh@@ -33,17 +33,17 @@ set -eEuo pipefail# and likely fail. so only ask for our specific target.(cd ${SRCDIR} && make dist_libstemmer_java)-for file in "SnowballStemmer.java" "Among.java" "SnowballProgram.java"; do- # add license header to files since they have none, otherwise rat will flip the fuck out+for file in "SnowballStemmer.java" "Among.java" "SnowballProgram.java" "CharArraySequence.java"; do+ # add license header to files since they have none.echo "/*" > ${DESTDIR}/${file}cat ${SRCDIR}/COPYING >> ${DESTDIR}/${file}echo "*/" >> ${DESTDIR}/${file}- cat ${SRCDIR}/java/org/tartarus/snowball/${file} >> ${DESTDIR}/${file}+ cat ${SRCDIR}/java/org/tartarus/snowball/${file} | sed 's/public class CharArraySequence/@SuppressWarnings("all") \0/' >> ${DESTDIR}/${file}donerm ${DESTDIR}/ext/*Stemmer.javarm -f ${TESTDSTDIR}/languages.txt-for file in ${SRCDIR}/java/org/tartarus/snowball/ext/*.java; do+for file in $(find ${SRCDIR}/java/org/tartarus/snowball/ext/ -name "*.java" | sort); do# title-case the classes (fooStemmer -> FooStemmer) so they obey normal java conventionsbase=$(basename $file)oldclazz="${base%.*}"diff --git a/lucene/CHANGES.txt b/lucene/CHANGES.txtindex 183f8be2063..3a2c230eefc 100644--- a/lucene/CHANGES.txt+++ b/lucene/CHANGES.txt@@ -53,6 +53,10 @@ API ChangesNew Features---------------------++* GITHUB#15505: Upgrade snowball to 2d2e312df56f2ede014a4ffb3e91e6dea43c24be. New stemmer: PolishStemmer (and+ PolishSnowballAnalyzer in the stempel package) (Justas Sakalauskas, Dawid Weiss)+* GITHUB#14097: Binary partitioning merge policy over float-valued vector field. (Mike Sokolov)* GITHUB#14178: Add a Faiss-based vector format in the sandbox module. (Kaival Parikh)diff --git a/lucene/analysis/common/build.gradle b/lucene/analysis/common/build.gradleindex 480f7b45e97..806827cb4c6 100644--- a/lucene/analysis/common/build.gradle+++ b/lucene/analysis/common/build.gradle@@ -36,7 +36,7 @@ dependencies {def resources = rootProject.file("gradle/regenerate/snowball")// git commit hash of source code https://github.com/snowballstem/snowball/-def snowballStemmerCommit = "34f3612e5e8c48975243bc2e87561abdac5aa9bb"+def snowballStemmerCommit = "2d2e312df56f2ede014a4ffb3e91e6dea43c24be"// git commit hash of stopwords https://github.com/snowballstem/snowball-websitedef snowballWebsiteCommit = "424fd1f75044160bb4a92f1daf08cce618459374"diff --git a/lucene/analysis/common/src/generated/checksums/regenerateSnowball.json b/lucene/analysis/common/src/generated/checksums/regenerateSnowball.jsonindex b53c20dea9f..a262a16c4d4 100644--- a/lucene/analysis/common/src/generated/checksums/regenerateSnowball.json+++ b/lucene/analysis/common/src/generated/checksums/regenerateSnowball.json@@ -1,37 +1,40 @@{- "lucene/analysis/common/src/java/org/tartarus/snowball/Among.java": "5371973cc30637273366f042e1cff920e0dd14f6",- "lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.java": "ea01ca896689fcd6690c634028b08ef23ef934c3",- "lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.java": "85bfc728393d7804f86f0def0467a12fd4b82fd3",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.java": "19540d4ec2522caff3a6e4748ebc17dc6b4b67c1",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.java": "3cd8b7d3fcecadafc57d0288020b04c056bbbed4",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.java": "d3c76ba45b6b8e016cc35488881e9d1139a62704",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java": "ea3fccdd12b769620d62b5dfbea2c0f2b395465e",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.java": "728f6cb684de292dde5e5532835c74dbaa347aba",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.java": "604db702d98d44cf6fd70550be3a511011c5737c",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java": "c9061cf6ceac73063732264a4d8997bc112d1514",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.java": "1a4455d7b5ff5eac072c3a04b66a64c453720a73",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.java": "d860a3d26d23756ae32feec6c4866666184ab08b",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.java": "eace09df7fcf65bb1752b394be99b704da0034c9",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.java": "29d8dc98725c1a52213a4674d085b91c50df944a",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.java": "4d460031c9bb3e66d5f5f4160b52aea3411a8d66",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.java": "14860ebdc789ed595fa5adbab45606babe8eb915",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.java": "d7abfa02a388f327d619d9a89581166c97af719d",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.java": "bb4763deb4f4ff04e5f27a10f92c0738e345462a",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.java": "32639d33d64cd0a5cc313e25fb6aedf12337443d",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.java": "58fae6d2be188191c86fa408ef38c1d5b0f248e6",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.java": "1529609eab33d9aa9e6d3fc7256e7b0562fd626b",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.java": "28f91d3aaa44e89e420e1e25fc2f70bf2189fd77",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.java": "c206634342849a72107703d8ea4e7bc33dcdb0c3",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.java": "f8dbfbcfa8a61ad2ebec2c5131d3d21d81239232",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.java": "3d3b3ca1f19d3cdf89bfec7a793dbec4c4cfd118",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.java": "419e836c26e1aa47d572d91f5af11ff37cfe5ab6",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.java": "8bc103e819ef3be555f71c67a59a5ed4a87f8ec1",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.java": "58cb7522a07c311aab420674953939d905f7d6d3",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.java": "484945a4d68847677c680887f61a7c3d00e6866e",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.java": "9afb99e75e15941c757a6bc0123bf9c05fadbe96",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.java": "3f5f20f3622716d37935a32616a2afad91a23bc3",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.java": "6392c0ac7b041717006e5847450be361f19a1e3f",- "lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.java": "9faaa89e7810fa81ca1f232f5f18bc83fe66c241",+ "lucene/analysis/common/src/java/org/tartarus/snowball/Among.java": "a6f5b9a43b3ca4ae7cbecea08e24d06774b0aee5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.java": "a91e02a89c0eb81163e73e61645ea5d27e851f0d",+ "lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.java": "2b2661c49ae61bb11aab089088ee442200d9b4f5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.java": "f3058c5cbf923b6cbb2829730bfd1659f89f0696",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.java": "9df577283f0f16349b6ee5e1cd0fc67434e37c2d",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.java": "e68ae1e4bb68f248c56b904d7843b533fd9d4cc6",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java": "0e898e514906d0560d4401ff0cfea5d8425ff2df",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.java": "790405d95a2c74c739daf9344988071b39ccd242",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.java": "dd0b8fd112f11c9af8a2c606ccb0bb134af2c93a",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/Dutch_porterStemmer.java": "ce42a3784a8902291809472419393cec3ae3f6d8",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java": "8c157b9c1473c77476bd066882ae7de10490a570",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/EsperantoStemmer.java": "4adf76f90089eca15baee0a41952b574b128bb6f",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.java": "408439c489c2a4fe716d99bbb2dcc3fdc556e5f9",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.java": "37ba448c2263895133e94c1c2b0ca861963b299e",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.java": "537d6a6dc835f1dd1ff8929216a9648292b54795",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.java": "941bcc87033d45fe77af83be793b78f4a34ab1d7",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.java": "83edf0a1786f0bb53e767fe9317c37ffb55150d6",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.java": "f6a3d64165f48d2d9fe44603f5eb526ac9108ca5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.java": "f0aff5e95f690e73660e91cc0e7b12ab0e99a8c5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.java": "cdc8203dda60757959d83bb286597cb5dcd39223",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.java": "9305ad4364b0c2fd053886b753b9ed425ad75ca4",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.java": "1fdd0bb92c2d042305e9c29daef2836876913c70",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.java": "db1bed30113a6d9a1cabb97752da783e0c677029",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.java": "4ed450305f43b23c73e850aa3f2b8fb8c95e7ada",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.java": "7568682a4db631a2b93e74834105a895eb5f0fa5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/PolishStemmer.java": "a101dc23a1c9b1f767b13f956f096d4838a57c74",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.java": "6bcc1b5de431f38941a23ee06e4d135b22703b32",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.java": "294249ddb80480b5e4bf36afdc9bf8154f2022aa",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.java": "4c25d2f7a9308e02355f27b7a137619037f9d336",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.java": "62213c94b6a54e29cf1ca32833d9d7db8f271bec",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.java": "fd479ca76ee495a2521951af292231e53ab9989c",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.java": "f4c8f1cc221942b0a072cb09f7559b7cbc402fc5",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.java": "e9e30243266bf525f3e33e7f2b94842b9cedcecb",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.java": "c9772927f353e5c30b70eb8ecaf8d342a71fc9fa",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.java": "0bf712cf9be8b713324956d953853da502f008e4",+ "lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.java": "70a0753bb236668447a714e1c9d0e9978e3ee54e","lucene/analysis/common/src/resources/org/apache/lucene/analysis/snowball/danish_stop.txt": "ce45d41833f77aa5a444134de4e4587b696f40c6","lucene/analysis/common/src/resources/org/apache/lucene/analysis/snowball/dutch_stop.txt": "f5e864c47ca680cf3b381152f37caafe1b694f57","lucene/analysis/common/src/resources/org/apache/lucene/analysis/snowball/english_stop.txt": "976e921dfbc48fb30ef08bd598d3172f1e5bbb1c",diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/Among.java b/lucene/analysis/common/src/java/org/tartarus/snowball/Among.javaindex dfea32bb943..48cb62bbd78 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/Among.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/Among.java@@ -2,7 +2,7 @@Copyright (c) 2001, Dr Martin PorterCopyright (c) 2004,2005, Richard BoultonCopyright (c) 2013, Yoshiki Shibukawa-Copyright (c) 2006,2007,2009,2010,2011,2014-2019, Olly Betts+Copyright (c) 2006-2025, Olly BettsAll rights reserved.Redistribution and use in source and binary forms, with or without@@ -79,4 +79,3 @@ public class Among {// Make sure this is not accessible outside package for Java security reasons!final MethodHandle method; /* method to use if substring matches */}-;diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/CharArraySequence.java b/lucene/analysis/common/src/java/org/tartarus/snowball/CharArraySequence.javanew file mode 100644index 00000000000..9f156c31b18--- /dev/null+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/CharArraySequence.java@@ -0,0 +1,66 @@+/*+Copyright (c) 2001, Dr Martin Porter+Copyright (c) 2004,2005, Richard Boulton+Copyright (c) 2013, Yoshiki Shibukawa+Copyright (c) 2006-2025, Olly Betts+All rights reserved.++Redistribution and use in source and binary forms, with or without+modification, are permitted provided that the following conditions+are met:++ 1. Redistributions of source code must retain the above copyright notice,+ this list of conditions and the following disclaimer.+ 2. Redistributions in binary form must reproduce the above copyright notice,+ this list of conditions and the following disclaimer in the documentation+ and/or other materials provided with the distribution.+ 3. Neither the name of the Snowball project nor the names of its contributors+ may be used to endorse or promote products derived from this software+ without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.+*/+package org.tartarus.snowball;++/** Internal class used by Snowball stemmers */+@SuppressWarnings("all")+public class CharArraySequence implements CharSequence {+ public CharArraySequence(char[] a, int len) {+ this.a = a;+ this.len = len;+ }++ public final char charAt(int index) {+ if (index < 0 || index >= len) {+ throw new StringIndexOutOfBoundsException(index);+ }+ return a[index];+ }++ public final int length() {+ return len;+ }++ public final CharSequence subSequence(int start, int end) {+ // Not needed for how we used CharSequence.+ throw new UnsupportedOperationException();+ }++ public final String toString() {+ if (a == null) return "";+ return new String(a, 0, len);+ }++ private final char[] a;++ private final int len;+}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.java b/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.javaindex 4ff9c5527d9..b9dd2dd3890 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballProgram.java@@ -2,7 +2,7 @@Copyright (c) 2001, Dr Martin PorterCopyright (c) 2004,2005, Richard BoultonCopyright (c) 2013, Yoshiki Shibukawa-Copyright (c) 2006,2007,2009,2010,2011,2014-2019, Olly Betts+Copyright (c) 2006-2025, Olly BettsAll rights reserved.Redistribution and use in source and binary forms, with or without@@ -39,7 +39,11 @@ import java.util.Arrays;/** Base class for a snowball stemmer */public class SnowballProgram implements Serializable {protected SnowballProgram() {- setCurrent("");+ cursor = 0;+ length = limit = 0;+ limit_backward = 0;+ bra = cursor;+ ket = limit;}static final long serialVersionUID = 2016072500L;@@ -96,7 +100,7 @@ public class SnowballProgram implements Serializable {}// current string- private char[] current;+ protected char[] current;protected int cursor;protected int length;@@ -127,7 +131,7 @@ public class SnowballProgram implements Serializable {protected boolean in_grouping(char[] s, int min, int max) {if (cursor >= limit) return false;- char ch = current[cursor];+ int ch = current[cursor];if (ch > max || ch < min) return false;ch -= min;if ((s[ch >> 3] & (0X1 << (ch & 0X7))) == 0) return false;@@ -135,9 +139,20 @@ public class SnowballProgram implements Serializable {return true;}+ protected boolean go_in_grouping(char[] s, int min, int max) {+ while (cursor < limit) {+ int ch = current[cursor];+ if (ch > max || ch < min) return true;+ ch -= min;+ if ((s[ch >> 3] & (0X1 << (ch & 0X7))) == 0) return true;+ cursor++;+ }+ return false;+ }+protected boolean in_grouping_b(char[] s, int min, int max) {if (cursor <= limit_backward) return false;- char ch = current[cursor - 1];+ int ch = current[cursor - 1];if (ch > max || ch < min) return false;ch -= min;if ((s[ch >> 3] & (0X1 << (ch & 0X7))) == 0) return false;@@ -145,9 +160,20 @@ public class SnowballProgram implements Serializable {return true;}+ protected boolean go_in_grouping_b(char[] s, int min, int max) {+ while (cursor > limit_backward) {+ int ch = current[cursor - 1];+ if (ch > max || ch < min) return true;+ ch -= min;+ if ((s[ch >> 3] & (0X1 << (ch & 0X7))) == 0) return true;+ cursor--;+ }+ return false;+ }+protected boolean out_grouping(char[] s, int min, int max) {if (cursor >= limit) return false;- char ch = current[cursor];+ int ch = current[cursor];if (ch > max || ch < min) {cursor++;return true;@@ -160,9 +186,23 @@ public class SnowballProgram implements Serializable {return false;}+ protected boolean go_out_grouping(char[] s, int min, int max) {+ while (cursor < limit) {+ int ch = current[cursor];+ if (ch <= max && ch >= min) {+ ch -= min;+ if ((s[ch >> 3] & (0X1 << (ch & 0X7))) != 0) {+ return true;+ }+ }+ cursor++;+ }+ return false;+ }+protected boolean out_grouping_b(char[] s, int min, int max) {if (cursor <= limit_backward) return false;- char ch = current[cursor - 1];+ int ch = current[cursor - 1];if (ch > max || ch < min) {cursor--;return true;@@ -175,6 +215,20 @@ public class SnowballProgram implements Serializable {return false;}+ protected boolean go_out_grouping_b(char[] s, int min, int max) {+ while (cursor > limit_backward) {+ int ch = current[cursor - 1];+ if (ch <= max && ch >= min) {+ ch -= min;+ if ((s[ch >> 3] & (0X1 << (ch & 0X7))) != 0) {+ return true;+ }+ }+ cursor--;+ }+ return false;+ }+protected boolean eq_s(CharSequence s) {if (limit - cursor < s.length()) return false;int i;@@ -195,7 +249,7 @@ public class SnowballProgram implements Serializable {return true;}- protected int find_among(Among v[]) {+ protected int find_among(Among[] v) {int i = 0;int j = v.length;@@ -246,16 +300,16 @@ public class SnowballProgram implements Serializable {if (common_i >= w.s.length) {cursor = c + w.s.length;if (w.method == null) return w.result;- boolean res = false;try {- res = (boolean) w.method.invokeExact(this);+ if ((boolean) w.method.invokeExact(this)) {+ cursor = c + w.s.length;+ return w.result;+ }} catch (Error | RuntimeException e) {throw e;} catch (Throwable e) {throw new UndeclaredThrowableException(e);}- cursor = c + w.s.length;- if (res) return w.result;}i = w.substring_i;if (i < 0) return 0;@@ -263,7 +317,7 @@ public class SnowballProgram implements Serializable {}// find_among_b is for backwards processing. Same comments apply- protected int find_among_b(Among v[]) {+ protected int find_among_b(Among[] v) {int i = 0;int j = v.length;@@ -309,17 +363,16 @@ public class SnowballProgram implements Serializable {if (common_i >= w.s.length) {cursor = c - w.s.length;if (w.method == null) return w.result;-- boolean res = false;try {- res = (boolean) w.method.invokeExact(this);+ if ((boolean) w.method.invokeExact(this)) {+ cursor = c - w.s.length;+ return w.result;+ }} catch (Error | RuntimeException e) {throw e;} catch (Throwable e) {throw new UndeclaredThrowableException(e);}- cursor = c - w.s.length;- if (res) return w.result;}i = w.substring_i;if (i < 0) return 0;@@ -363,6 +416,7 @@ public class SnowballProgram implements Serializable {protected void slice_from(CharSequence s) {slice_check();replace_s(bra, ket, s);+ ket = bra + s.length();}protected void slice_del() {@@ -375,19 +429,6 @@ public class SnowballProgram implements Serializable {if (c_bra <= ket) ket += adjustment;}- /* Copy the slice into the supplied StringBuilder */- protected void slice_to(StringBuilder s) {- slice_check();- int len = ket - bra;- s.setLength(0);- s.append(current, bra, len);- }-- protected void assign_to(StringBuilder s) {- s.setLength(0);- s.append(current, 0, limit);- }-/*extern void debug(struct SN_env * z, int number, int line_count){ int i;@@ -411,4 +452,3 @@ public class SnowballProgram implements Serializable {*/}-;diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.javaindex ba9f969f833..6a518f2a9a7 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/SnowballStemmer.java@@ -2,7 +2,7 @@Copyright (c) 2001, Dr Martin PorterCopyright (c) 2004,2005, Richard BoultonCopyright (c) 2013, Yoshiki Shibukawa-Copyright (c) 2006,2007,2009,2010,2011,2014-2019, Olly Betts+Copyright (c) 2006-2025, Olly BettsAll rights reserved.Redistribution and use in source and binary forms, with or withoutdiff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.javaindex 5689b3e17a8..486833afcb3 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArabicStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from arabic.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from arabic.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0640", -1, 1),new Among("\u064B", -1, 1),new Among("\u064C", -1, 1),@@ -161,7 +161,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\uFEFC", -1, 48)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u0622", -1, 1),new Among("\u0623", -1, 1),new Among("\u0624", -1, 1),@@ -169,7 +169,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0626", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u0622", -1, 1),new Among("\u0623", -1, 1),new Among("\u0624", -1, 2),@@ -177,14 +177,14 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0626", -1, 3)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u0627\u0644", -1, 2),new Among("\u0628\u0627\u0644", -1, 1),new Among("\u0643\u0627\u0644", -1, 1),new Among("\u0644\u0644", -1, 2)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("\u0623\u0622", -1, 2),new Among("\u0623\u0623", -1, 1),new Among("\u0623\u0624", -1, 1),@@ -192,36 +192,36 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0623\u0627", -1, 3)};- private static final Among a_5[] = {new Among("\u0641", -1, 1), new Among("\u0648", -1, 1)};+ private static final Among[] a_5 = {new Among("\u0641", -1, 1), new Among("\u0648", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("\u0627\u0644", -1, 2),new Among("\u0628\u0627\u0644", -1, 1),new Among("\u0643\u0627\u0644", -1, 1),new Among("\u0644\u0644", -1, 2)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("\u0628", -1, 1),new Among("\u0628\u0627", 0, -1),new Among("\u0628\u0628", 0, 2),new Among("\u0643\u0643", -1, 3)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("\u0633\u0623", -1, 4),new Among("\u0633\u062A", -1, 2),new Among("\u0633\u0646", -1, 3),new Among("\u0633\u064A", -1, 1)};- private static final Among a_9[] = {+ private static final Among[] a_9 = {new Among("\u062A\u0633\u062A", -1, 1),new Among("\u0646\u0633\u062A", -1, 1),new Among("\u064A\u0633\u062A", -1, 1)};- private static final Among a_10[] = {+ private static final Among[] a_10 = {new Among("\u0643\u0645\u0627", -1, 3),new Among("\u0647\u0645\u0627", -1, 3),new Among("\u0646\u0627", -1, 2),@@ -234,21 +234,11 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u064A", -1, 1)};- private static final Among a_11[] = {new Among("\u0646", -1, 1)};-- private static final Among a_12[] = {+ private static final Among[] a_11 = {new Among("\u0627", -1, 1), new Among("\u0648", -1, 1), new Among("\u064A", -1, 1)};- private static final Among a_13[] = {new Among("\u0627\u062A", -1, 1)};-- private static final Among a_14[] = {new Among("\u062A", -1, 1)};-- private static final Among a_15[] = {new Among("\u0629", -1, 1)};-- private static final Among a_16[] = {new Among("\u064A", -1, 1)};-- private static final Among a_17[] = {+ private static final Among[] a_12 = {new Among("\u0643\u0645\u0627", -1, 3),new Among("\u0647\u0645\u0627", -1, 3),new Among("\u0646\u0627", -1, 2),@@ -263,7 +253,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0646\u064A", -1, 2)};- private static final Among a_18[] = {+ private static final Among[] a_13 = {new Among("\u0627", -1, 1),new Among("\u062A\u0627", 0, 2),new Among("\u062A\u0645\u0627", 0, 4),@@ -277,16 +267,14 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u064A", -1, 1)};- private static final Among a_19[] = {+ private static final Among[] a_14 = {new Among("\u0648\u0627", -1, 1), new Among("\u062A\u0645", -1, 1)};- private static final Among a_20[] = {+ private static final Among[] a_15 = {new Among("\u0648", -1, 1), new Among("\u062A\u0645\u0648", 0, 2)};- private static final Among a_21[] = {new Among("\u0649", -1, 1)};-private boolean B_is_defined;private boolean B_is_verb;private boolean B_is_noun;@@ -778,7 +766,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step1b() {ket = cursor;- if (find_among_b(a_11) == 0) {+ if (!(eq_s_b("\u0646"))) {return false;}bra = cursor;@@ -791,7 +779,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step2a() {ket = cursor;- if (find_among_b(a_12) == 0) {+ if (find_among_b(a_11) == 0) {return false;}bra = cursor;@@ -804,7 +792,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step2b() {ket = cursor;- if (find_among_b(a_13) == 0) {+ if (!(eq_s_b("\u0627\u062A"))) {return false;}bra = cursor;@@ -817,7 +805,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step2c1() {ket = cursor;- if (find_among_b(a_14) == 0) {+ if (!(eq_s_b("\u062A"))) {return false;}bra = cursor;@@ -830,7 +818,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step2c2() {ket = cursor;- if (find_among_b(a_15) == 0) {+ if (!(eq_s_b("\u0629"))) {return false;}bra = cursor;@@ -843,7 +831,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Noun_Step3() {ket = cursor;- if (find_among_b(a_16) == 0) {+ if (!(eq_s_b("\u064A"))) {return false;}bra = cursor;@@ -857,7 +845,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Verb_Step1() {int among_var;ket = cursor;- among_var = find_among_b(a_17);+ among_var = find_among_b(a_12);if (among_var == 0) {return false;}@@ -888,7 +876,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Verb_Step2a() {int among_var;ket = cursor;- among_var = find_among_b(a_18);+ among_var = find_among_b(a_13);if (among_var == 0) {return false;}@@ -924,7 +912,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Verb_Step2b() {ket = cursor;- if (find_among_b(a_19) == 0) {+ if (find_among_b(a_14) == 0) {return false;}bra = cursor;@@ -938,7 +926,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_Verb_Step2c() {int among_var;ket = cursor;- among_var = find_among_b(a_20);+ among_var = find_among_b(a_15);if (among_var == 0) {return false;}@@ -962,7 +950,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Suffix_All_alef_maqsura() {ket = cursor;- if (find_among_b(a_21) == 0) {+ if (!(eq_s_b("\u0649"))) {return false;}bra = cursor;@@ -981,44 +969,44 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {r_Normalize_pre();limit_backward = cursor;cursor = limit;- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{lab1:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab2:{- if (!(B_is_verb)) {+ if (!B_is_verb) {break lab2;}lab3:{- int v_5 = limit - cursor;+ int v_4 = limit - cursor;lab4:{{- int v_6 = 1;+ int v_5 = 1;while (true) {- int v_7 = limit - cursor;+ int v_6 = limit - cursor;lab5:{if (!r_Suffix_Verb_Step1()) {break lab5;}- v_6--;+ v_5--;continue;}- cursor = limit - v_7;+ cursor = limit - v_6;break;}- if (v_6 > 0) {+ if (v_5 > 0) {break lab4;}}lab6:{- int v_8 = limit - cursor;+ int v_7 = limit - cursor;lab7:{if (!r_Suffix_Verb_Step2a()) {@@ -1026,7 +1014,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab6;}- cursor = limit - v_8;+ cursor = limit - v_7;lab8:{if (!r_Suffix_Verb_Step2c()) {@@ -1034,7 +1022,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab6;}- cursor = limit - v_8;+ cursor = limit - v_7;if (cursor <= limit_backward) {break lab4;}@@ -1042,7 +1030,7 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_5;+ cursor = limit - v_4;lab9:{if (!r_Suffix_Verb_Step2b()) {@@ -1050,25 +1038,25 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_5;+ cursor = limit - v_4;if (!r_Suffix_Verb_Step2a()) {break lab2;}}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;lab10:{- if (!(B_is_noun)) {+ if (!B_is_noun) {break lab10;}- int v_9 = limit - cursor;+ int v_8 = limit - cursor;lab11:{lab12:{- int v_10 = limit - cursor;+ int v_9 = limit - cursor;lab13:{if (!r_Suffix_Noun_Step2c2()) {@@ -1076,46 +1064,42 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab12;}- cursor = limit - v_10;+ cursor = limit - v_9;lab14:{- lab15:- {- if (!(B_is_defined)) {- break lab15;- }+ if (B_is_defined) {break lab14;}if (!r_Suffix_Noun_Step1a()) {break lab14;}- lab16:+ lab15:{- int v_12 = limit - cursor;- lab17:+ int v_10 = limit - cursor;+ lab16:{if (!r_Suffix_Noun_Step2a()) {- break lab17;+ break lab16;}- break lab16;+ break lab15;}- cursor = limit - v_12;- lab18:+ cursor = limit - v_10;+ lab17:{if (!r_Suffix_Noun_Step2b()) {- break lab18;+ break lab17;}- break lab16;+ break lab15;}- cursor = limit - v_12;- lab19:+ cursor = limit - v_10;+ lab18:{if (!r_Suffix_Noun_Step2c1()) {- break lab19;+ break lab18;}- break lab16;+ break lab15;}- cursor = limit - v_12;+ cursor = limit - v_10;if (cursor <= limit_backward) {break lab14;}@@ -1123,55 +1107,51 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab12;}- cursor = limit - v_10;- lab20:+ cursor = limit - v_9;+ lab19:{if (!r_Suffix_Noun_Step1b()) {- break lab20;+ break lab19;}- lab21:+ lab20:{- int v_13 = limit - cursor;- lab22:+ int v_11 = limit - cursor;+ lab21:{if (!r_Suffix_Noun_Step2a()) {- break lab22;+ break lab21;}- break lab21;+ break lab20;}- cursor = limit - v_13;- lab23:+ cursor = limit - v_11;+ lab22:{if (!r_Suffix_Noun_Step2b()) {- break lab23;+ break lab22;}- break lab21;+ break lab20;}- cursor = limit - v_13;+ cursor = limit - v_11;if (!r_Suffix_Noun_Step2c1()) {- break lab20;+ break lab19;}}break lab12;}- cursor = limit - v_10;- lab24:+ cursor = limit - v_9;+ lab23:{- lab25:- {- if (!(B_is_defined)) {- break lab25;- }- break lab24;+ if (B_is_defined) {+ break lab23;}if (!r_Suffix_Noun_Step2a()) {- break lab24;+ break lab23;}break lab12;}- cursor = limit - v_10;+ cursor = limit - v_9;if (!r_Suffix_Noun_Step2b()) {- cursor = limit - v_9;+ cursor = limit - v_8;break lab11;}}@@ -1181,72 +1161,72 @@ public class ArabicStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;if (!r_Suffix_All_alef_maqsura()) {break lab0;}}}- cursor = limit - v_3;+ cursor = limit - v_2;cursor = limit_backward;- int v_15 = cursor;- lab26:+ int v_12 = cursor;+ lab24:{- int v_16 = cursor;- lab27:+ int v_13 = cursor;+ lab25:{if (!r_Prefix_Step1()) {- cursor = v_16;- break lab27;+ cursor = v_13;+ break lab25;}}- int v_17 = cursor;- lab28:+ int v_14 = cursor;+ lab26:{if (!r_Prefix_Step2()) {- cursor = v_17;- break lab28;+ cursor = v_14;+ break lab26;}}- lab29:+ lab27:{- int v_18 = cursor;- lab30:+ int v_15 = cursor;+ lab28:{if (!r_Prefix_Step3a_Noun()) {- break lab30;+ break lab28;}- break lab29;+ break lab27;}- cursor = v_18;- lab31:+ cursor = v_15;+ lab29:{- if (!(B_is_noun)) {- break lab31;+ if (!B_is_noun) {+ break lab29;}if (!r_Prefix_Step3b_Noun()) {- break lab31;+ break lab29;}- break lab29;+ break lab27;}- cursor = v_18;- if (!(B_is_verb)) {- break lab26;+ cursor = v_15;+ if (!B_is_verb) {+ break lab24;}- int v_19 = cursor;- lab32:+ int v_16 = cursor;+ lab30:{if (!r_Prefix_Step3_Verb()) {- cursor = v_19;- break lab32;+ cursor = v_16;+ break lab30;}}if (!r_Prefix_Step4_Verb()) {- break lab26;+ break lab24;}}}- cursor = v_15;+ cursor = v_12;r_Normalize_post();return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.javaindex 0b90c8a6436..7605e8c2055 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ArmenianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from armenian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from armenian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0580\u0578\u0580\u0564", -1, 1),new Among("\u0565\u0580\u0578\u0580\u0564", 0, 1),new Among("\u0561\u056C\u056B", -1, 1),@@ -40,7 +40,7 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0562\u0561\u0580", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u0561", -1, 1),new Among("\u0561\u0581\u0561", 0, 1),new Among("\u0565\u0581\u0561", 0, 1),@@ -114,7 +114,7 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u057E\u0565\u0581\u056B\u0576\u0584", 69, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u0578\u0580\u0564", -1, 1),new Among("\u0578\u0582\u0575\u0569", -1, 1),new Among("\u0578\u0582\u0570\u056B", -1, 1),@@ -157,7 +157,7 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0561\u0580\u0584", 27, 1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u057D\u0561", -1, 1),new Among("\u057E\u0561", -1, 1),new Among("\u0561\u0574\u0562", -1, 1),@@ -217,7 +217,7 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0578\u0582\u0581", 47, 1)};- private static final char g_v[] = {209, 4, 128, 0, 18};+ private static final char[] g_v = {209, 4, 128, 0, 18};private int I_p2;private int I_pV;@@ -228,63 +228,23 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = cursor;lab0:{- golab1:- while (true) {- lab2:- {- if (!(in_grouping(g_v, 1377, 1413))) {- break lab2;- }- break golab1;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 1377, 1413)) {+ break lab0;}+ cursor++;I_pV = cursor;- golab3:- while (true) {- lab4:- {- if (!(out_grouping(g_v, 1377, 1413))) {- break lab4;- }- break golab3;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_in_grouping(g_v, 1377, 1413)) {+ break lab0;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 1377, 1413))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_out_grouping(g_v, 1377, 1413)) {+ break lab0;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 1377, 1413))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 1377, 1413)) {+ break lab0;}+ cursor++;I_p2 = cursor;}cursor = v_1;@@ -346,21 +306,21 @@ public class ArmenianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_3 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;- int v_4 = limit - cursor;+ int v_2 = limit - cursor;r_ending();- cursor = limit - v_4;- int v_5 = limit - cursor;+ cursor = limit - v_2;+ int v_3 = limit - cursor;r_verb();- cursor = limit - v_5;- int v_6 = limit - cursor;+ cursor = limit - v_3;+ int v_4 = limit - cursor;r_adjective();- cursor = limit - v_6;- int v_7 = limit - cursor;+ cursor = limit - v_4;+ int v_5 = limit - cursor;r_noun();- cursor = limit - v_7;- limit_backward = v_3;+ cursor = limit - v_5;+ limit_backward = v_1;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.javaindex 35aa1268100..d1437b4eb77 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/BasqueStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from basque.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from basque.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("idea", -1, 1),new Among("bidea", 0, 1),new Among("kidea", 0, 1),@@ -45,7 +45,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("kizuna", -1, 1),new Among("era", -1, 1),new Among("bera", 28, 1),- new Among("arabera", 29, 4),+ new Among("arabera", 29, -1),new Among("kera", 28, 1),new Among("pera", 28, 1),new Among("orra", -1, 1),@@ -96,7 +96,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("rean", 77, 1),new Among("kan", 76, 1),new Among("etan", 76, 1),- new Among("atseden", -1, 3),+ new Among("atseden", -1, -1),new Among("men", -1, 1),new Among("pen", -1, 1),new Among("kin", -1, 1),@@ -118,7 +118,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("atu", 99, 1),new Among("aldatu", 100, 1),new Among("tatu", 100, 1),- new Among("baditu", 99, 5),+ new Among("baditu", 99, -1),new Among("ez", -1, 1),new Among("errez", 104, 1),new Among("tzez", 104, 1),@@ -126,7 +126,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("kaitz", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("ada", -1, 1),new Among("kada", 0, 1),new Among("anda", -1, 1),@@ -189,7 +189,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ontzia", -1, 1),new Among("ka", -1, 1),new Among("joka", 60, 3),- new Among("aurka", 60, 10),+ new Among("aurka", 60, -1),new Among("ska", 60, 1),new Among("xka", 60, 1),new Among("zka", 60, 1),@@ -306,7 +306,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("di", -1, 1),new Among("aldi", 176, 1),new Among("taldi", 177, 1),- new Among("geldi", 176, 8),+ new Among("geldi", 176, -1),new Among("handi", 176, 1),new Among("mendi", 176, 1),new Among("gei", -1, 1),@@ -375,7 +375,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("zino", 244, 1),new Among("ro", -1, 1),new Among("aro", 246, 1),- new Among("igaro", 247, 9),+ new Among("igaro", 247, -1),new Among("taro", 247, 1),new Among("zaro", 247, 1),new Among("ero", 246, 1),@@ -393,7 +393,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ar", -1, 1),new Among("dar", 263, 1),new Among("behar", 263, 1),- new Among("zehar", 263, 7),+ new Among("zehar", 263, -1),new Among("liar", 263, 1),new Among("tiar", 263, 1),new Among("tar", 263, 1),@@ -424,7 +424,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("koitz", 293, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("zlea", -1, 2),new Among("keria", -1, 1),new Among("la", -1, 1),@@ -446,7 +446,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("to", -1, 1)};- private static final char g_v[] = {17, 65, 16};+ private static final char[] g_v = {17, 65, 16};private int I_p2;private int I_p1;@@ -475,40 +475,20 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 117))) {break lab4;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 117))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab4;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 117)) {+ break lab4;}+ cursor++;break lab3;}cursor = v_3;if (!(in_grouping(g_v, 97, 117))) {break lab2;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 117))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab2;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 117)) {+ break lab2;}+ cursor++;}break lab1;}@@ -516,31 +496,21 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 117))) {break lab0;}- lab9:+ lab5:{- int v_6 = cursor;- lab10:+ int v_4 = cursor;+ lab6:{if (!(out_grouping(g_v, 97, 117))) {- break lab10;+ break lab6;}- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 117))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab10;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 117)) {+ break lab6;}- break lab9;+ cursor++;+ break lab5;}- cursor = v_6;+ cursor = v_4;if (!(in_grouping(g_v, 97, 117))) {break lab0;}@@ -553,69 +523,29 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {I_pV = cursor;}cursor = v_1;- int v_8 = cursor;- lab13:+ int v_5 = cursor;+ lab7:{- golab14:- while (true) {- lab15:- {- if (!(in_grouping(g_v, 97, 117))) {- break lab15;- }- break golab14;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 117)) {+ break lab7;}- golab16:- while (true) {- lab17:- {- if (!(out_grouping(g_v, 97, 117))) {- break lab17;- }- break golab16;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 117)) {+ break lab7;}+ cursor++;I_p1 = cursor;- golab18:- while (true) {- lab19:- {- if (!(in_grouping(g_v, 97, 117))) {- break lab19;- }- break golab18;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 117)) {+ break lab7;}- golab20:- while (true) {- lab21:- {- if (!(out_grouping(g_v, 97, 117))) {- break lab21;- }- break golab20;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 117)) {+ break lab7;}+ cursor++;I_p2 = cursor;}- cursor = v_8;+ cursor = v_5;return true;}@@ -652,15 +582,6 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();break;- case 3:- slice_from("atseden");- break;- case 4:- slice_from("arabera");- break;- case 5:- slice_from("baditu");- break;}return true;}@@ -701,18 +622,6 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {case 6:slice_from("minutu");break;- case 7:- slice_from("zehar");- break;- case 8:- slice_from("geldi");- break;- case 9:- slice_from("igaro");- break;- case 10:- slice_from("aurka");- break;}return true;}@@ -745,7 +654,7 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {limit_backward = cursor;cursor = limit;while (true) {- int v_2 = limit - cursor;+ int v_1 = limit - cursor;lab0:{if (!r_aditzak()) {@@ -753,11 +662,11 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {}continue;}- cursor = limit - v_2;+ cursor = limit - v_1;break;}while (true) {- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab1:{if (!r_izenak()) {@@ -765,12 +674,12 @@ public class BasqueStemmer extends org.tartarus.snowball.SnowballStemmer {}continue;}- cursor = limit - v_3;+ cursor = limit - v_2;break;}- int v_4 = limit - cursor;+ int v_3 = limit - cursor;r_adjetiboak();- cursor = limit - v_4;+ cursor = limit - v_3;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.javaindex ee7b3be1c31..09ccdc37173 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/CatalanStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from catalan.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from catalan.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 7),new Among("\u00B7", 0, 6),new Among("\u00E0", 0, 1),@@ -30,7 +30,7 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00FC", 0, 5)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("la", -1, 1),new Among("-la", 0, 1),new Among("sela", 0, 1),@@ -72,7 +72,7 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("'t", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ica", -1, 4),new Among("l\u00F3gica", 0, 3),new Among("enca", -1, 1),@@ -275,7 +275,7 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("aci\u00F3", 198, 1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("aba", -1, 1),new Among("esca", -1, 1),new Among("isca", -1, 1),@@ -561,7 +561,7 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("i\u00F3", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("a", -1, 1),new Among("e", -1, 1),new Among("i", -1, 1),@@ -586,7 +586,7 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F3", -1, 1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 129, 81, 6, 10};@@ -599,63 +599,23 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = cursor;lab0:{- golab1:- while (true) {- lab2:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab2;- }- break golab1;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab0;}- golab3:- while (true) {- lab4:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab4;- }- break golab3;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ break lab0;}+ cursor++;I_p1 = cursor;- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab0;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ break lab0;}+ cursor++;I_p2 = cursor;}cursor = v_1;@@ -824,15 +784,15 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_2 = limit - cursor;+ int v_1 = limit - cursor;r_attached_pronoun();- cursor = limit - v_2;- int v_3 = limit - cursor;+ cursor = limit - v_1;+ int v_2 = limit - cursor;lab0:{lab1:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab2:{if (!r_standard_suffix()) {@@ -840,20 +800,20 @@ public class CatalanStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;if (!r_verb_suffix()) {break lab0;}}}- cursor = limit - v_3;- int v_5 = limit - cursor;+ cursor = limit - v_2;+ int v_4 = limit - cursor;r_residual_suffix();- cursor = limit - v_5;+ cursor = limit - v_4;cursor = limit_backward;- int v_6 = cursor;+ int v_5 = cursor;r_cleaning();- cursor = v_6;+ cursor = v_5;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.javaindex ca305c60327..8d3f7770507 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DanishStemmer.java@@ -1,20 +1,22 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from danish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;+import java.util.Arrays;import org.tartarus.snowball.Among;+import org.tartarus.snowball.CharArraySequence;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from danish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("hed", -1, 1),new Among("ethed", 0, 1),new Among("ered", -1, 1),@@ -49,14 +51,14 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("eret", 30, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("gd", -1, -1),new Among("dt", -1, -1),new Among("gt", -1, -1),new Among("kt", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ig", -1, 1),new Among("lig", 0, 1),new Among("elig", 1, 1),@@ -64,19 +66,20 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("l\u00F8st", -1, 2)};- private static final char g_c[] = {119, 223, 119, 1};+ private static final char[] g_c = {119, 223, 119, 1};- private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 0, 128};+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 0, 128};- private static final char g_s_ending[] = {+ private static final char[] g_s_ending = {239, 254, 42, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16};- private int I_x;private int I_p1;- private java.lang.StringBuilder S_ch = new java.lang.StringBuilder();+ private char[] S_ch = new char[8];+ private int LS_ch = 0;private boolean r_mark_regions() {+ int I_x;I_p1 = limit;int v_1 = cursor;{@@ -88,42 +91,19 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {}I_x = cursor;cursor = v_1;- golab0:- while (true) {- int v_2 = cursor;- lab1:- {- if (!(in_grouping(g_v, 97, 248))) {- break lab1;- }- cursor = v_2;- break golab0;- }- cursor = v_2;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 248)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_v, 97, 248))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 248)) {+ return false;}+ cursor++;I_p1 = cursor;- lab4:+ lab0:{if (I_p1 >= I_x) {- break lab4;+ break lab0;}I_p1 = I_x;}@@ -135,16 +115,16 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_0);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_del();@@ -164,15 +144,15 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_3 = limit_backward;+ int v_2 = limit_backward;limit_backward = I_p1;ket = cursor;if (find_among_b(a_1) == 0) {- limit_backward = v_3;+ limit_backward = v_2;return false;}bra = cursor;- limit_backward = v_3;+ limit_backward = v_2;cursor = limit - v_1;if (cursor <= limit_backward) {return false;@@ -202,22 +182,22 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_3 = limit_backward;+ int v_2 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_2);if (among_var == 0) {- limit_backward = v_3;+ limit_backward = v_2;return false;}bra = cursor;- limit_backward = v_3;+ limit_backward = v_2;switch (among_var) {case 1:slice_del();- int v_4 = limit - cursor;+ int v_3 = limit - cursor;r_consonant_pair();- cursor = limit - v_4;+ cursor = limit - v_3;break;case 2:slice_from("l\u00F8s");@@ -230,17 +210,23 @@ public class DanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;if (!(in_grouping_b(g_c, 98, 122))) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- slice_to(S_ch);- limit_backward = v_2;- if (!(eq_s_b(S_ch))) {+ slice_check();+ if (S_ch.length < ket - bra) {+ S_ch = Arrays.copyOfRange(current, bra, ket);+ } else {+ System.arraycopy(current, bra, S_ch, 0, ket - bra);+ }+ LS_ch = ket - bra;+ limit_backward = v_1;+ if (!(eq_s_b(new CharArraySequence(S_ch, LS_ch)))) {return false;}slice_del();diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.javaindex 2160da4dd88..7e1f2d39b78 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/DutchStemmer.java@@ -1,559 +1,1607 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from dutch.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;+import java.util.Arrays;import org.tartarus.snowball.Among;+import org.tartarus.snowball.CharArraySequence;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from dutch.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class DutchStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {- new Among("", -1, 6),- new Among("\u00E1", 0, 1),- new Among("\u00E4", 0, 1),- new Among("\u00E9", 0, 2),- new Among("\u00EB", 0, 2),- new Among("\u00ED", 0, 3),- new Among("\u00EF", 0, 3),- new Among("\u00F3", 0, 4),- new Among("\u00F6", 0, 4),- new Among("\u00FA", 0, 5),- new Among("\u00FC", 0, 5)+ private static final Among[] a_0 = {+ new Among("a", -1, 1),+ new Among("e", -1, 2),+ new Among("o", -1, 1),+ new Among("u", -1, 1),+ new Among("\u00E0", -1, 1),+ new Among("\u00E1", -1, 1),+ new Among("\u00E2", -1, 1),+ new Among("\u00E4", -1, 1),+ new Among("\u00E8", -1, 2),+ new Among("\u00E9", -1, 2),+ new Among("\u00EA", -1, 2),+ new Among("e\u00EB", -1, 3),+ new Among("i\u00EB", -1, 4),+ new Among("\u00F2", -1, 1),+ new Among("\u00F3", -1, 1),+ new Among("\u00F4", -1, 1),+ new Among("\u00F6", -1, 1),+ new Among("\u00F9", -1, 1),+ new Among("\u00FA", -1, 1),+ new Among("\u00FB", -1, 1),+ new Among("\u00FC", -1, 1)};- private static final Among a_1[] = {- new Among("", -1, 3), new Among("I", 0, 2), new Among("Y", 0, 1)+ private static final Among[] a_1 = {+ new Among("nde", -1, 8),+ new Among("en", -1, 7),+ new Among("s", -1, 2),+ new Among("'s", 2, 1),+ new Among("es", 2, 4),+ new Among("ies", 4, 3),+ new Among("aus", 2, 6),+ new Among("\u00E9s", 2, 5)};- private static final Among a_2[] = {- new Among("dd", -1, -1), new Among("kk", -1, -1), new Among("tt", -1, -1)+ private static final Among[] a_2 = {+ new Among("de", -1, 5),+ new Among("ge", -1, 2),+ new Among("ische", -1, 4),+ new Among("je", -1, 1),+ new Among("lijke", -1, 3),+ new Among("le", -1, 9),+ new Among("ene", -1, 10),+ new Among("re", -1, 8),+ new Among("se", -1, 7),+ new Among("te", -1, 6),+ new Among("ieve", -1, 11)};- private static final Among a_3[] = {- new Among("ene", -1, 2),- new Among("se", -1, 3),- new Among("en", -1, 2),- new Among("heden", 2, 1),- new Among("s", -1, 3)+ private static final Among[] a_3 = {+ new Among("heid", -1, 3),+ new Among("fie", -1, 7),+ new Among("gie", -1, 8),+ new Among("atie", -1, 1),+ new Among("isme", -1, 5),+ new Among("ing", -1, 5),+ new Among("arij", -1, 6),+ new Among("erij", -1, 5),+ new Among("sel", -1, 3),+ new Among("rder", -1, 4),+ new Among("ster", -1, 3),+ new Among("iteit", -1, 2),+ new Among("dst", -1, 10),+ new Among("tst", -1, 9)};- private static final Among a_4[] = {- new Among("end", -1, 1),- new Among("ig", -1, 2),- new Among("ing", -1, 1),- new Among("lijk", -1, 3),- new Among("baar", -1, 4),- new Among("bar", -1, 5)+ private static final Among[] a_4 = {+ new Among("end", -1, 9),+ new Among("atief", -1, 2),+ new Among("erig", -1, 9),+ new Among("achtig", -1, 3),+ new Among("ioneel", -1, 1),+ new Among("baar", -1, 3),+ new Among("laar", -1, 5),+ new Among("naar", -1, 4),+ new Among("raar", -1, 6),+ new Among("eriger", -1, 9),+ new Among("achtiger", -1, 3),+ new Among("lijker", -1, 8),+ new Among("tant", -1, 7),+ new Among("erigst", -1, 9),+ new Among("achtigst", -1, 3),+ new Among("lijkst", -1, 8)};- private static final Among a_5[] = {- new Among("aa", -1, -1),- new Among("ee", -1, -1),- new Among("oo", -1, -1),- new Among("uu", -1, -1)+ private static final Among[] a_5 = {+ new Among("ig", -1, 1), new Among("iger", -1, 1), new Among("igst", -1, 1)};- private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128};+ private static final Among[] a_6 = {+ new Among("ft", -1, 2), new Among("kt", -1, 1), new Among("pt", -1, 3)+ };++ private static final Among[] a_7 = {+ new Among("bb", -1, 1),+ new Among("cc", -1, 2),+ new Among("dd", -1, 3),+ new Among("ff", -1, 4),+ new Among("gg", -1, 5),+ new Among("hh", -1, 6),+ new Among("jj", -1, 7),+ new Among("kk", -1, 8),+ new Among("ll", -1, 9),+ new Among("mm", -1, 10),+ new Among("nn", -1, 11),+ new Among("pp", -1, 12),+ new Among("qq", -1, 13),+ new Among("rr", -1, 14),+ new Among("ss", -1, 15),+ new Among("tt", -1, 16),+ new Among("v", -1, 4),+ new Among("vv", 16, 17),+ new Among("ww", -1, 18),+ new Among("xx", -1, 19),+ new Among("z", -1, 15),+ new Among("zz", 20, 20)+ };++ private static final Among[] a_8 = {new Among("d", -1, 1), new Among("t", -1, 2)};++ private static final Among[] a_9 = {+ new Among("", -1, -1),+ new Among("eft", 0, 1),+ new Among("vaa", 0, 1),+ new Among("val", 0, 1),+ new Among("vali", 3, -1),+ new Among("vare", 0, 1)+ };++ private static final Among[] a_10 = {new Among("\u00EB", -1, 1), new Among("\u00EF", -1, 2)};++ private static final Among[] a_11 = {new Among("\u00EB", -1, 1), new Among("\u00EF", -1, 2)};- private static final char g_v_I[] = {- 1, 0, 0, 17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128+ private static final char[] g_E = {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 120};++ private static final char[] g_AIOU = {+ 1, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 11, 120, 46, 15+ };++ private static final char[] g_AEIOU = {+ 17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 139, 127, 46, 15+ };++ private static final char[] g_v = {+ 17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 139, 127, 46, 15};- private static final char g_v_j[] = {17, 67, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128};+ private static final char[] g_v_WX = {+ 17, 65, 208, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 139, 127, 46, 15+ };+ private boolean B_GE_removed;private int I_p2;private int I_p1;- private boolean B_e_found;+ private char[] S_ch = new char[8];+ private int LS_ch = 0;- private boolean r_prelude() {- int among_var;- int v_1 = cursor;- while (true) {- int v_2 = cursor;- lab0:- {- bra = cursor;- among_var = find_among(a_0);- ket = cursor;- switch (among_var) {- case 1:- slice_from("a");- break;- case 2:- slice_from("e");- break;- case 3:- slice_from("i");- break;- case 4:- slice_from("o");- break;- case 5:- slice_from("u");- break;- case 6:- if (cursor >= limit) {- break lab0;- }- cursor++;- break;- }- continue;- }- cursor = v_2;- break;- }- cursor = v_1;- int v_3 = cursor;- lab1:- {- bra = cursor;- if (!(eq_s("y"))) {- cursor = v_3;- break lab1;- }- ket = cursor;- slice_from("Y");- }- while (true) {- int v_4 = cursor;- lab2:- {- golab3:- while (true) {- int v_5 = cursor;- lab4:- {- if (!(in_grouping(g_v, 97, 232))) {- break lab4;- }- bra = cursor;- lab5:- {- int v_6 = cursor;- lab6:- {- if (!(eq_s("i"))) {- break lab6;- }- ket = cursor;- if (!(in_grouping(g_v, 97, 232))) {- break lab6;- }- slice_from("I");- break lab5;- }- cursor = v_6;- if (!(eq_s("y"))) {- break lab4;- }- ket = cursor;- slice_from("Y");- }- cursor = v_5;- break golab3;- }- cursor = v_5;- if (cursor >= limit) {- break lab2;- }- cursor++;- }- continue;- }- cursor = v_4;- break;- }- return true;+ private boolean r_R1() {+ return I_p1 <= cursor;}- private boolean r_mark_regions() {- I_p1 = limit;- I_p2 = limit;- golab0:- while (true) {+ private boolean r_R2() {+ return I_p2 <= cursor;+ }++ private boolean r_V() {+ int v_1 = limit - cursor;+ lab0:+ {+ int v_2 = limit - cursor;lab1:{- if (!(in_grouping(g_v, 97, 232))) {+ if (!(in_grouping_b(g_v, 97, 252))) {break lab1;}- break golab0;- }- if (cursor >= limit) {- return false;- }- cursor++;- }- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_v, 97, 232))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;- }- I_p1 = cursor;- lab4:- {- if (I_p1 >= 3) {- break lab4;- }- I_p1 = 3;- }- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 232))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- return false;- }- cursor++;- }- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 232))) {- break lab8;- }- break golab7;+ break lab0;}- if (cursor >= limit) {+ cursor = limit - v_2;+ if (!(eq_s_b("ij"))) {return false;}- cursor++;- }- I_p2 = cursor;- return true;- }-- private boolean r_postlude() {- int among_var;- while (true) {- int v_1 = cursor;- lab0:- {- bra = cursor;- among_var = find_among(a_1);- ket = cursor;- switch (among_var) {- case 1:- slice_from("y");- break;- case 2:- slice_from("i");- break;- case 3:- if (cursor >= limit) {- break lab0;- }- cursor++;- break;- }- continue;- }- cursor = v_1;- break;}+ cursor = limit - v_1;return true;}- private boolean r_R1() {- return I_p1 <= cursor;- }-- private boolean r_R2() {- return I_p2 <= cursor;- }-- private boolean r_undouble() {+ private boolean r_VX() {int v_1 = limit - cursor;- if (find_among_b(a_2) == 0) {- return false;- }- cursor = limit - v_1;- ket = cursor;if (cursor <= limit_backward) {return false;}cursor--;- bra = cursor;- slice_del();- return true;- }-- private boolean r_e_ending() {- B_e_found = false;- ket = cursor;- if (!(eq_s_b("e"))) {- return false;- }- bra = cursor;- if (!r_R1()) {- return false;- }- int v_1 = limit - cursor;- if (!(out_grouping_b(g_v, 97, 232))) {- return false;+ lab0:+ {+ int v_2 = limit - cursor;+ lab1:+ {+ if (!(in_grouping_b(g_v, 97, 252))) {+ break lab1;+ }+ break lab0;+ }+ cursor = limit - v_2;+ if (!(eq_s_b("ij"))) {+ return false;+ }}cursor = limit - v_1;- slice_del();- B_e_found = true;- if (!r_undouble()) {- return false;- }return true;}- private boolean r_en_ending() {- if (!r_R1()) {- return false;- }+ private boolean r_C() {int v_1 = limit - cursor;- if (!(out_grouping_b(g_v, 97, 232))) {- return false;- }- cursor = limit - v_1;{int v_2 = limit - cursor;lab0:{- if (!(eq_s_b("gem"))) {+ if (!(eq_s_b("ij"))) {break lab0;}return false;}cursor = limit - v_2;}- slice_del();- if (!r_undouble()) {+ if (!(out_grouping_b(g_v, 97, 252))) {return false;}+ cursor = limit - v_1;return true;}- private boolean r_standard_suffix() {+ private boolean r_lengthen_V() {int among_var;int v_1 = limit - cursor;lab0:{+ if (!(out_grouping_b(g_v_WX, 97, 252))) {+ break lab0;+ }ket = cursor;- among_var = find_among_b(a_3);+ among_var = find_among_b(a_0);if (among_var == 0) {break lab0;}bra = cursor;switch (among_var) {case 1:- if (!r_R1()) {- break lab0;- }- slice_from("heid");- break;- case 2:- if (!r_en_ending()) {- break lab0;+ int v_2 = limit - cursor;+ lab1:+ {+ int v_3 = limit - cursor;+ lab2:+ {+ if (!(out_grouping_b(g_AEIOU, 97, 252))) {+ break lab2;+ }+ break lab1;+ }+ cursor = limit - v_3;+ if (cursor > limit_backward) {+ break lab0;+ }}- break;- case 3:- if (!r_R1()) {- break lab0;+ cursor = limit - v_2;+ slice_check();+ if (S_ch.length < ket - bra) {+ S_ch = Arrays.copyOfRange(current, bra, ket);+ } else {+ System.arraycopy(current, bra, S_ch, 0, ket - bra);}- if (!(out_grouping_b(g_v_j, 97, 232))) {- break lab0;+ LS_ch = ket - bra;+ {+ int c = cursor;+ insert(cursor, cursor, new CharArraySequence(S_ch, LS_ch));+ cursor = c;}- slice_del();break;- }- }- cursor = limit - v_1;- int v_2 = limit - cursor;- r_e_ending();- cursor = limit - v_2;- int v_3 = limit - cursor;- lab1:- {- ket = cursor;- if (!(eq_s_b("heid"))) {- break lab1;- }- bra = cursor;- if (!r_R2()) {- break lab1;- }- {- int v_4 = limit - cursor;- lab2:- {- if (!(eq_s_b("c"))) {- break lab2;+ case 2:+ int v_4 = limit - cursor;+ lab3:+ {+ int v_5 = limit - cursor;+ lab4:+ {+ if (!(out_grouping_b(g_AEIOU, 97, 252))) {+ break lab4;+ }+ break lab3;+ }+ cursor = limit - v_5;+ if (cursor > limit_backward) {+ break lab0;+ }}- break lab1;- }- cursor = limit - v_4;+ {+ int v_6 = limit - cursor;+ lab5:+ {+ lab6:+ {+ int v_7 = limit - cursor;+ lab7:+ {+ if (!(in_grouping_b(g_AIOU, 97, 252))) {+ break lab7;+ }+ break lab6;+ }+ cursor = limit - v_7;+ if (!(in_grouping_b(g_E, 101, 235))) {+ break lab5;+ }+ if (cursor > limit_backward) {+ break lab5;+ }+ }+ break lab0;+ }+ cursor = limit - v_6;+ }+ {+ int v_8 = limit - cursor;+ lab8:+ {+ if (cursor <= limit_backward) {+ break lab8;+ }+ cursor--;+ if (!(in_grouping_b(g_AIOU, 97, 252))) {+ break lab8;+ }+ if (!(out_grouping_b(g_AEIOU, 97, 252))) {+ break lab8;+ }+ break lab0;+ }+ cursor = limit - v_8;+ }+ cursor = limit - v_4;+ slice_check();+ if (S_ch.length < ket - bra) {+ S_ch = Arrays.copyOfRange(current, bra, ket);+ } else {+ System.arraycopy(current, bra, S_ch, 0, ket - bra);+ }+ LS_ch = ket - bra;+ {+ int c = cursor;+ insert(cursor, cursor, new CharArraySequence(S_ch, LS_ch));+ cursor = c;+ }+ break;+ case 3:+ slice_from("e\u00EBe");+ break;+ case 4:+ slice_from("iee");+ break;+ }+ }+ cursor = limit - v_1;+ return true;+ }++ private boolean r_Step_1() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_1);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ slice_del();+ break;+ case 2:+ if (!r_R1()) {+ return false;+ }+ {+ int v_1 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("t"))) {+ break lab0;+ }+ if (!r_R1()) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_1;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ break;+ case 3:+ if (!r_R1()) {+ return false;+ }+ slice_from("ie");+ break;+ case 4:+ lab1:+ {+ int v_2 = limit - cursor;+ lab2:+ {+ int v_3 = limit - cursor;+ if (!(eq_s_b("ar"))) {+ break lab2;+ }+ if (!r_R1()) {+ break lab2;+ }+ if (!r_C()) {+ break lab2;+ }+ cursor = limit - v_3;+ slice_del();+ r_lengthen_V();+ break lab1;+ }+ cursor = limit - v_2;+ lab3:+ {+ int v_4 = limit - cursor;+ if (!(eq_s_b("er"))) {+ break lab3;+ }+ if (!r_R1()) {+ break lab3;+ }+ if (!r_C()) {+ break lab3;+ }+ cursor = limit - v_4;+ slice_del();+ break lab1;+ }+ cursor = limit - v_2;+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_from("e");+ }+ break;+ case 5:+ if (!r_R1()) {+ return false;+ }+ slice_from("\u00E9");+ break;+ case 6:+ if (!r_R1()) {+ return false;+ }+ if (!r_V()) {+ return false;+ }+ slice_from("au");+ break;+ case 7:+ lab4:+ {+ int v_5 = limit - cursor;+ lab5:+ {+ if (!(eq_s_b("hed"))) {+ break lab5;+ }+ if (!r_R1()) {+ break lab5;+ }+ bra = cursor;+ slice_from("heid");+ break lab4;+ }+ cursor = limit - v_5;+ lab6:+ {+ if (!(eq_s_b("nd"))) {+ break lab6;+ }+ slice_del();+ break lab4;+ }+ cursor = limit - v_5;+ lab7:+ {+ if (!(eq_s_b("d"))) {+ break lab7;+ }+ if (!r_R1()) {+ break lab7;+ }+ if (!r_C()) {+ break lab7;+ }+ bra = cursor;+ slice_del();+ break lab4;+ }+ cursor = limit - v_5;+ lab8:+ {+ lab9:+ {+ int v_6 = limit - cursor;+ lab10:+ {+ if (!(eq_s_b("i"))) {+ break lab10;+ }+ break lab9;+ }+ cursor = limit - v_6;+ if (!(eq_s_b("j"))) {+ break lab8;+ }+ }+ if (!r_V()) {+ break lab8;+ }+ slice_del();+ break lab4;+ }+ cursor = limit - v_5;+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ r_lengthen_V();+ }+ break;+ case 8:+ slice_from("nd");+ break;+ }+ return true;+ }++ private boolean r_Step_2() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_2);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("'t"))) {+ break lab1;+ }+ bra = cursor;+ slice_del();+ break lab0;+ }+ cursor = limit - v_1;+ lab2:+ {+ if (!(eq_s_b("et"))) {+ break lab2;+ }+ bra = cursor;+ if (!r_R1()) {+ break lab2;+ }+ if (!r_C()) {+ break lab2;+ }+ slice_del();+ break lab0;+ }+ cursor = limit - v_1;+ lab3:+ {+ if (!(eq_s_b("rnt"))) {+ break lab3;+ }+ bra = cursor;+ slice_from("rn");+ break lab0;+ }+ cursor = limit - v_1;+ lab4:+ {+ if (!(eq_s_b("t"))) {+ break lab4;+ }+ bra = cursor;+ if (!r_R1()) {+ break lab4;+ }+ if (!r_VX()) {+ break lab4;+ }+ slice_del();+ break lab0;+ }+ cursor = limit - v_1;+ lab5:+ {+ if (!(eq_s_b("ink"))) {+ break lab5;+ }+ bra = cursor;+ slice_from("ing");+ break lab0;+ }+ cursor = limit - v_1;+ lab6:+ {+ if (!(eq_s_b("mp"))) {+ break lab6;+ }+ bra = cursor;+ slice_from("m");+ break lab0;+ }+ cursor = limit - v_1;+ lab7:+ {+ if (!(eq_s_b("'"))) {+ break lab7;+ }+ bra = cursor;+ if (!r_R1()) {+ break lab7;+ }+ slice_del();+ break lab0;+ }+ cursor = limit - v_1;+ bra = cursor;+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ }+ break;+ case 2:+ if (!r_R1()) {+ return false;+ }+ slice_from("g");+ break;+ case 3:+ if (!r_R1()) {+ return false;+ }+ slice_from("lijk");+ break;+ case 4:+ if (!r_R1()) {+ return false;+ }+ slice_from("isch");+ break;+ case 5:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ break;+ case 6:+ if (!r_R1()) {+ return false;+ }+ slice_from("t");+ break;+ case 7:+ if (!r_R1()) {+ return false;+ }+ slice_from("s");+ break;+ case 8:+ if (!r_R1()) {+ return false;+ }+ slice_from("r");+ break;+ case 9:+ if (!r_R1()) {+ return false;+ }+ slice_del();+ insert(cursor, cursor, "l");+ r_lengthen_V();+ break;+ case 10:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ insert(cursor, cursor, "en");+ r_lengthen_V();+ break;+ case 11:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_from("ief");+ break;+ }+ return true;+ }++ private boolean r_Step_3() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_3);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ if (!r_R1()) {+ return false;+ }+ slice_from("eer");+ break;+ case 2:+ if (!r_R1()) {+ return false;+ }+ slice_del();+ r_lengthen_V();+ break;+ case 3:+ if (!r_R1()) {+ return false;+ }+ slice_del();+ break;+ case 4:+ slice_from("r");+ break;+ case 5:+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("ild"))) {+ break lab1;+ }+ slice_from("er");+ break lab0;+ }+ cursor = limit - v_1;+ if (!r_R1()) {+ return false;+ }+ slice_del();+ r_lengthen_V();+ }+ break;+ case 6:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_from("aar");+ break;+ case 7:+ if (!r_R2()) {+ return false;+ }+ slice_del();+ insert(cursor, cursor, "f");+ r_lengthen_V();+ break;+ case 8:+ if (!r_R2()) {+ return false;+ }+ slice_del();+ insert(cursor, cursor, "g");+ r_lengthen_V();+ break;+ case 9:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_from("t");+ break;+ case 10:+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ slice_from("d");+ break;+ }+ return true;+ }++ private boolean r_Step_4() {+ int among_var;+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ ket = cursor;+ among_var = find_among_b(a_4);+ if (among_var == 0) {+ break lab1;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ if (!r_R1()) {+ break lab1;+ }+ slice_from("ie");+ break;+ case 2:+ if (!r_R1()) {+ break lab1;+ }+ slice_from("eer");+ break;+ case 3:+ if (!r_R1()) {+ break lab1;+ }+ slice_del();+ break;+ case 4:+ if (!r_R1()) {+ break lab1;+ }+ if (!r_V()) {+ break lab1;+ }+ slice_from("n");+ break;+ case 5:+ if (!r_R1()) {+ break lab1;+ }+ if (!r_V()) {+ break lab1;+ }+ slice_from("l");+ break;+ case 6:+ if (!r_R1()) {+ break lab1;+ }+ if (!r_V()) {+ break lab1;+ }+ slice_from("r");+ break;+ case 7:+ if (!r_R1()) {+ break lab1;+ }+ slice_from("teer");+ break;+ case 8:+ if (!r_R1()) {+ break lab1;+ }+ slice_from("lijk");+ break;+ case 9:+ if (!r_R1()) {+ break lab1;+ }+ if (!r_C()) {+ break lab1;+ }+ slice_del();+ r_lengthen_V();+ break;+ }+ break lab0;+ }+ cursor = limit - v_1;+ ket = cursor;+ if (find_among_b(a_5) == 0) {+ return false;+ }+ bra = cursor;+ if (!r_R1()) {+ return false;+ }+ {+ int v_2 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("inn"))) {+ break lab2;+ }+ if (cursor > limit_backward) {+ break lab2;+ }+ return false;+ }+ cursor = limit - v_2;+ }+ if (!r_C()) {+ return false;+ }+ slice_del();+ r_lengthen_V();+ }+ return true;+ }++ private boolean r_Step_7() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_6);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ slice_from("k");+ break;+ case 2:+ slice_from("f");+ break;+ case 3:+ slice_from("p");+ break;+ }+ return true;+ }++ private boolean r_Step_6() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_7);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ slice_from("b");+ break;+ case 2:+ slice_from("c");+ break;+ case 3:+ slice_from("d");+ break;+ case 4:+ slice_from("f");+ break;+ case 5:+ slice_from("g");+ break;+ case 6:+ slice_from("h");+ break;+ case 7:+ slice_from("j");+ break;+ case 8:+ slice_from("k");+ break;+ case 9:+ slice_from("l");+ break;+ case 10:+ slice_from("m");+ break;+ case 11:+ {+ int v_1 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("i"))) {+ break lab0;+ }+ if (cursor > limit_backward) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_1;+ }+ slice_from("n");+ break;+ case 12:+ slice_from("p");+ break;+ case 13:+ slice_from("q");+ break;+ case 14:+ slice_from("r");+ break;+ case 15:+ slice_from("s");+ break;+ case 16:+ slice_from("t");+ break;+ case 17:+ slice_from("v");+ break;+ case 18:+ slice_from("w");+ break;+ case 19:+ slice_from("x");+ break;+ case 20:+ slice_from("z");+ break;+ }+ return true;+ }++ private boolean r_Step_1c() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_8);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ if (!r_R1()) {+ return false;+ }+ if (!r_C()) {+ return false;+ }+ switch (among_var) {+ case 1:+ {+ int v_1 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("n"))) {+ break lab0;+ }+ if (!r_R1()) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_1;+ }+ lab1:+ {+ int v_2 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("in"))) {+ break lab2;+ }+ if (cursor > limit_backward) {+ break lab2;+ }+ slice_from("n");+ break lab1;+ }+ cursor = limit - v_2;+ slice_del();+ }+ break;+ case 2:+ {+ int v_3 = limit - cursor;+ lab3:+ {+ if (!(eq_s_b("h"))) {+ break lab3;+ }+ if (!r_R1()) {+ break lab3;+ }+ return false;+ }+ cursor = limit - v_3;+ }+ {+ int v_4 = limit - cursor;+ lab4:+ {+ if (!(eq_s_b("en"))) {+ break lab4;+ }+ if (cursor > limit_backward) {+ break lab4;+ }+ return false;+ }+ cursor = limit - v_4;+ }+ slice_del();+ break;+ }+ return true;+ }++ private boolean r_Lose_prefix() {+ int among_var;+ bra = cursor;+ if (!(eq_s("ge"))) {+ return false;+ }+ ket = cursor;+ int v_1 = cursor;+ {+ int c = cursor + 3;+ if (c > limit) {+ return false;+ }+ cursor = c;+ }+ cursor = v_1;+ int v_2 = cursor;+ golab0:+ while (true) {+ int v_3 = cursor;+ lab1:+ {+ lab2:+ {+ int v_4 = cursor;+ lab3:+ {+ if (!(eq_s("ij"))) {+ break lab3;+ }+ break lab2;+ }+ cursor = v_4;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab1;+ }+ }+ break golab0;+ }+ cursor = v_3;+ if (cursor >= limit) {+ return false;+ }+ cursor++;+ }+ while (true) {+ int v_5 = cursor;+ lab4:+ {+ lab5:+ {+ int v_6 = cursor;+ lab6:+ {+ if (!(eq_s("ij"))) {+ break lab6;+ }+ break lab5;+ }+ cursor = v_6;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab4;+ }+ }+ continue;}- slice_del();- ket = cursor;- if (!(eq_s_b("en"))) {- break lab1;+ cursor = v_5;+ break;+ }+ lab7:+ {+ if (cursor < limit) {+ break lab7;}+ return false;+ }+ cursor = v_2;+ among_var = find_among(a_9);+ switch (among_var) {+ case 1:+ return false;+ }+ B_GE_removed = true;+ slice_del();+ int v_7 = cursor;+ lab8:+ {bra = cursor;- if (!r_en_ending()) {- break lab1;+ among_var = find_among(a_10);+ if (among_var == 0) {+ break lab8;+ }+ ket = cursor;+ switch (among_var) {+ case 1:+ slice_from("e");+ break;+ case 2:+ slice_from("i");+ break;}}- cursor = limit - v_3;- int v_5 = limit - cursor;- lab3:+ cursor = v_7;+ return true;+ }++ private boolean r_Lose_infix() {+ int among_var;+ if (cursor >= limit) {+ return false;+ }+ cursor++;+ golab0:+ while (true) {+ lab1:+ {+ bra = cursor;+ if (!(eq_s("ge"))) {+ break lab1;+ }+ ket = cursor;+ break golab0;+ }+ if (cursor >= limit) {+ return false;+ }+ cursor++;+ }+ int v_1 = cursor;{- ket = cursor;- among_var = find_among_b(a_4);- if (among_var == 0) {- break lab3;+ int c = cursor + 3;+ if (c > limit) {+ return false;+ }+ cursor = c;+ }+ cursor = v_1;+ int v_2 = cursor;+ golab2:+ while (true) {+ int v_3 = cursor;+ lab3:+ {+ lab4:+ {+ int v_4 = cursor;+ lab5:+ {+ if (!(eq_s("ij"))) {+ break lab5;+ }+ break lab4;+ }+ cursor = v_4;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab3;+ }+ }+ break golab2;+ }+ cursor = v_3;+ if (cursor >= limit) {+ return false;+ }+ cursor++;+ }+ while (true) {+ int v_5 = cursor;+ lab6:+ {+ lab7:+ {+ int v_6 = cursor;+ lab8:+ {+ if (!(eq_s("ij"))) {+ break lab8;+ }+ break lab7;+ }+ cursor = v_6;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab6;+ }+ }+ continue;+ }+ cursor = v_5;+ break;+ }+ lab9:+ {+ if (cursor < limit) {+ break lab9;}+ return false;+ }+ cursor = v_2;+ B_GE_removed = true;+ slice_del();+ int v_7 = cursor;+ lab10:+ {bra = cursor;+ among_var = find_among(a_11);+ if (among_var == 0) {+ break lab10;+ }+ ket = cursor;switch (among_var) {case 1:- if (!r_R2()) {- break lab3;+ slice_from("e");+ break;+ case 2:+ slice_from("i");+ break;+ }+ }+ cursor = v_7;+ return true;+ }++ private boolean r_measure() {+ I_p1 = limit;+ I_p2 = limit;+ int v_1 = cursor;+ lab0:+ {+ while (true) {+ lab1:+ {+ if (!(out_grouping(g_v, 97, 252))) {+ break lab1;}- slice_del();- lab4:+ continue;+ }+ break;+ }+ {+ int v_2 = 1;+ while (true) {+ int v_3 = cursor;+ lab2:{- int v_6 = limit - cursor;- lab5:+ lab3:{- ket = cursor;- if (!(eq_s_b("ig"))) {- break lab5;- }- bra = cursor;- if (!r_R2()) {- break lab5;- }+ int v_4 = cursor;+ lab4:{- int v_7 = limit - cursor;- lab6:- {- if (!(eq_s_b("e"))) {- break lab6;- }- break lab5;+ if (!(eq_s("ij"))) {+ break lab4;}- cursor = limit - v_7;+ break lab3;+ }+ cursor = v_4;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab2;}- slice_del();- break lab4;- }- cursor = limit - v_6;- if (!r_undouble()) {- break lab3;}+ v_2--;+ continue;}+ cursor = v_3;break;- case 2:- if (!r_R2()) {- break lab3;+ }+ if (v_2 > 0) {+ break lab0;+ }+ }+ if (!(out_grouping(g_v, 97, 252))) {+ break lab0;+ }+ I_p1 = cursor;+ while (true) {+ lab5:+ {+ if (!(out_grouping(g_v, 97, 252))) {+ break lab5;}+ continue;+ }+ break;+ }+ {+ int v_5 = 1;+ while (true) {+ int v_6 = cursor;+ lab6:{- int v_8 = limit - cursor;lab7:{- if (!(eq_s_b("e"))) {+ int v_7 = cursor;+ lab8:+ {+ if (!(eq_s("ij"))) {+ break lab8;+ }break lab7;}- break lab3;+ cursor = v_7;+ if (!(in_grouping(g_v, 97, 252))) {+ break lab6;+ }}- cursor = limit - v_8;- }- slice_del();- break;- case 3:- if (!r_R2()) {- break lab3;- }- slice_del();- if (!r_e_ending()) {- break lab3;- }- break;- case 4:- if (!r_R2()) {- break lab3;+ v_5--;+ continue;}- slice_del();- break;- case 5:- if (!r_R2()) {- break lab3;- }- if (!(B_e_found)) {- break lab3;- }- slice_del();+ cursor = v_6;break;+ }+ if (v_5 > 0) {+ break lab0;+ }}- }- cursor = limit - v_5;- int v_9 = limit - cursor;- lab8:- {- if (!(out_grouping_b(g_v_I, 73, 232))) {- break lab8;- }- int v_10 = limit - cursor;- if (find_among_b(a_5) == 0) {- break lab8;- }- if (!(out_grouping_b(g_v, 97, 232))) {- break lab8;- }- cursor = limit - v_10;- ket = cursor;- if (cursor <= limit_backward) {- break lab8;+ if (!(out_grouping(g_v, 97, 252))) {+ break lab0;}- cursor--;- bra = cursor;- slice_del();+ I_p2 = cursor;}- cursor = limit - v_9;+ cursor = v_1;return true;}@Overridepublic boolean stem() {- int v_1 = cursor;- r_prelude();- cursor = v_1;- int v_2 = cursor;- r_mark_regions();- cursor = v_2;+ boolean B_stemmed;+ B_stemmed = false;+ r_measure();+ limit_backward = cursor;+ cursor = limit;+ int v_1 = limit - cursor;+ lab0:+ {+ if (!r_Step_1()) {+ break lab0;+ }+ B_stemmed = true;+ }+ cursor = limit - v_1;+ int v_2 = limit - cursor;+ lab1:+ {+ if (!r_Step_2()) {+ break lab1;+ }+ B_stemmed = true;+ }+ cursor = limit - v_2;+ int v_3 = limit - cursor;+ lab2:+ {+ if (!r_Step_3()) {+ break lab2;+ }+ B_stemmed = true;+ }+ cursor = limit - v_3;+ int v_4 = limit - cursor;+ lab3:+ {+ if (!r_Step_4()) {+ break lab3;+ }+ B_stemmed = true;+ }+ cursor = limit - v_4;+ cursor = limit_backward;+ B_GE_removed = false;+ int v_5 = cursor;+ lab4:+ {+ int v_6 = cursor;+ if (!r_Lose_prefix()) {+ break lab4;+ }+ cursor = v_6;+ r_measure();+ }+ cursor = v_5;+ limit_backward = cursor;+ cursor = limit;+ int v_7 = limit - cursor;+ lab5:+ {+ if (!B_GE_removed) {+ break lab5;+ }+ B_stemmed = true;+ if (!r_Step_1c()) {+ break lab5;+ }+ }+ cursor = limit - v_7;+ cursor = limit_backward;+ B_GE_removed = false;+ int v_8 = cursor;+ lab6:+ {+ int v_9 = cursor;+ if (!r_Lose_infix()) {+ break lab6;+ }+ cursor = v_9;+ r_measure();+ }+ cursor = v_8;limit_backward = cursor;cursor = limit;- r_standard_suffix();+ int v_10 = limit - cursor;+ lab7:+ {+ if (!B_GE_removed) {+ break lab7;+ }+ B_stemmed = true;+ if (!r_Step_1c()) {+ break lab7;+ }+ }+ cursor = limit - v_10;+ cursor = limit_backward;+ limit_backward = cursor;+ cursor = limit;+ int v_11 = limit - cursor;+ lab8:+ {+ if (!r_Step_7()) {+ break lab8;+ }+ B_stemmed = true;+ }+ cursor = limit - v_11;+ int v_12 = limit - cursor;+ lab9:+ {+ if (!B_stemmed) {+ break lab9;+ }+ if (!r_Step_6()) {+ break lab9;+ }+ }+ cursor = limit - v_12;cursor = limit_backward;- int v_4 = cursor;- r_postlude();- cursor = v_4;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/Dutch_porterStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/Dutch_porterStemmer.javanew file mode 100644index 00000000000..b82d5e695c6--- /dev/null+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/Dutch_porterStemmer.java@@ -0,0 +1,531 @@+// Generated from dutch_porter.sbl by Snowball 3.0.0 - https://snowballstem.org/++package org.tartarus.snowball.ext;++import org.tartarus.snowball.Among;++/**+ * This class implements the stemming algorithm defined by a snowball script.+ *+ * <p>Generated from dutch_porter.sbl by Snowball 3.0.0 - https://snowballstem.org/+ */+@SuppressWarnings("unused")+public class Dutch_porterStemmer extends org.tartarus.snowball.SnowballStemmer {++ private static final long serialVersionUID = 1L;++ private static final Among[] a_0 = {+ new Among("", -1, 6),+ new Among("\u00E1", 0, 1),+ new Among("\u00E4", 0, 1),+ new Among("\u00E9", 0, 2),+ new Among("\u00EB", 0, 2),+ new Among("\u00ED", 0, 3),+ new Among("\u00EF", 0, 3),+ new Among("\u00F3", 0, 4),+ new Among("\u00F6", 0, 4),+ new Among("\u00FA", 0, 5),+ new Among("\u00FC", 0, 5)+ };++ private static final Among[] a_1 = {+ new Among("", -1, 3), new Among("I", 0, 2), new Among("Y", 0, 1)+ };++ private static final Among[] a_2 = {+ new Among("dd", -1, -1), new Among("kk", -1, -1), new Among("tt", -1, -1)+ };++ private static final Among[] a_3 = {+ new Among("ene", -1, 2),+ new Among("se", -1, 3),+ new Among("en", -1, 2),+ new Among("heden", 2, 1),+ new Among("s", -1, 3)+ };++ private static final Among[] a_4 = {+ new Among("end", -1, 1),+ new Among("ig", -1, 2),+ new Among("ing", -1, 1),+ new Among("lijk", -1, 3),+ new Among("baar", -1, 4),+ new Among("bar", -1, 5)+ };++ private static final Among[] a_5 = {+ new Among("aa", -1, -1),+ new Among("ee", -1, -1),+ new Among("oo", -1, -1),+ new Among("uu", -1, -1)+ };++ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128};++ private static final char[] g_v_I = {+ 1, 0, 0, 17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128+ };++ private static final char[] g_v_j = {17, 67, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128};++ private int I_p2;+ private int I_p1;+ private boolean B_e_found;++ private boolean r_prelude() {+ int among_var;+ int v_1 = cursor;+ while (true) {+ int v_2 = cursor;+ lab0:+ {+ bra = cursor;+ among_var = find_among(a_0);+ ket = cursor;+ switch (among_var) {+ case 1:+ slice_from("a");+ break;+ case 2:+ slice_from("e");+ break;+ case 3:+ slice_from("i");+ break;+ case 4:+ slice_from("o");+ break;+ case 5:+ slice_from("u");+ break;+ case 6:+ if (cursor >= limit) {+ break lab0;+ }+ cursor++;+ break;+ }+ continue;+ }+ cursor = v_2;+ break;+ }+ cursor = v_1;+ int v_3 = cursor;+ lab1:+ {+ bra = cursor;+ if (!(eq_s("y"))) {+ cursor = v_3;+ break lab1;+ }+ ket = cursor;+ slice_from("Y");+ }+ while (true) {+ int v_4 = cursor;+ lab2:+ {+ if (!go_out_grouping(g_v, 97, 232)) {+ break lab2;+ }+ cursor++;+ int v_5 = cursor;+ lab3:+ {+ bra = cursor;+ lab4:+ {+ int v_6 = cursor;+ lab5:+ {+ if (!(eq_s("i"))) {+ break lab5;+ }+ ket = cursor;+ int v_7 = cursor;+ lab6:+ {+ if (!(in_grouping(g_v, 97, 232))) {+ break lab6;+ }+ slice_from("I");+ }+ cursor = v_7;+ break lab4;+ }+ cursor = v_6;+ if (!(eq_s("y"))) {+ cursor = v_5;+ break lab3;+ }+ ket = cursor;+ slice_from("Y");+ }+ }+ continue;+ }+ cursor = v_4;+ break;+ }+ return true;+ }++ private boolean r_mark_regions() {+ int I_x;+ I_p1 = limit;+ I_p2 = limit;+ int v_1 = cursor;+ {+ int c = cursor + 3;+ if (c > limit) {+ return false;+ }+ cursor = c;+ }+ I_x = cursor;+ cursor = v_1;+ if (!go_out_grouping(g_v, 97, 232)) {+ return false;+ }+ cursor++;+ if (!go_in_grouping(g_v, 97, 232)) {+ return false;+ }+ cursor++;+ I_p1 = cursor;+ lab0:+ {+ if (I_p1 >= I_x) {+ break lab0;+ }+ I_p1 = I_x;+ }+ if (!go_out_grouping(g_v, 97, 232)) {+ return false;+ }+ cursor++;+ if (!go_in_grouping(g_v, 97, 232)) {+ return false;+ }+ cursor++;+ I_p2 = cursor;+ return true;+ }++ private boolean r_postlude() {+ int among_var;+ while (true) {+ int v_1 = cursor;+ lab0:+ {+ bra = cursor;+ among_var = find_among(a_1);+ ket = cursor;+ switch (among_var) {+ case 1:+ slice_from("y");+ break;+ case 2:+ slice_from("i");+ break;+ case 3:+ if (cursor >= limit) {+ break lab0;+ }+ cursor++;+ break;+ }+ continue;+ }+ cursor = v_1;+ break;+ }+ return true;+ }++ private boolean r_R1() {+ return I_p1 <= cursor;+ }++ private boolean r_R2() {+ return I_p2 <= cursor;+ }++ private boolean r_undouble() {+ int v_1 = limit - cursor;+ if (find_among_b(a_2) == 0) {+ return false;+ }+ cursor = limit - v_1;+ ket = cursor;+ if (cursor <= limit_backward) {+ return false;+ }+ cursor--;+ bra = cursor;+ slice_del();+ return true;+ }++ private boolean r_e_ending() {+ B_e_found = false;+ ket = cursor;+ if (!(eq_s_b("e"))) {+ return false;+ }+ bra = cursor;+ if (!r_R1()) {+ return false;+ }+ int v_1 = limit - cursor;+ if (!(out_grouping_b(g_v, 97, 232))) {+ return false;+ }+ cursor = limit - v_1;+ slice_del();+ B_e_found = true;+ return r_undouble();+ }++ private boolean r_en_ending() {+ if (!r_R1()) {+ return false;+ }+ int v_1 = limit - cursor;+ if (!(out_grouping_b(g_v, 97, 232))) {+ return false;+ }+ cursor = limit - v_1;+ {+ int v_2 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("gem"))) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_2;+ }+ slice_del();+ return r_undouble();+ }++ private boolean r_standard_suffix() {+ int among_var;+ int v_1 = limit - cursor;+ lab0:+ {+ ket = cursor;+ among_var = find_among_b(a_3);+ if (among_var == 0) {+ break lab0;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ if (!r_R1()) {+ break lab0;+ }+ slice_from("heid");+ break;+ case 2:+ if (!r_en_ending()) {+ break lab0;+ }+ break;+ case 3:+ if (!r_R1()) {+ break lab0;+ }+ if (!(out_grouping_b(g_v_j, 97, 232))) {+ break lab0;+ }+ slice_del();+ break;+ }+ }+ cursor = limit - v_1;+ int v_2 = limit - cursor;+ r_e_ending();+ cursor = limit - v_2;+ int v_3 = limit - cursor;+ lab1:+ {+ ket = cursor;+ if (!(eq_s_b("heid"))) {+ break lab1;+ }+ bra = cursor;+ if (!r_R2()) {+ break lab1;+ }+ {+ int v_4 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("c"))) {+ break lab2;+ }+ break lab1;+ }+ cursor = limit - v_4;+ }+ slice_del();+ ket = cursor;+ if (!(eq_s_b("en"))) {+ break lab1;+ }+ bra = cursor;+ if (!r_en_ending()) {+ break lab1;+ }+ }+ cursor = limit - v_3;+ int v_5 = limit - cursor;+ lab3:+ {+ ket = cursor;+ among_var = find_among_b(a_4);+ if (among_var == 0) {+ break lab3;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ if (!r_R2()) {+ break lab3;+ }+ slice_del();+ lab4:+ {+ int v_6 = limit - cursor;+ lab5:+ {+ ket = cursor;+ if (!(eq_s_b("ig"))) {+ break lab5;+ }+ bra = cursor;+ if (!r_R2()) {+ break lab5;+ }+ {+ int v_7 = limit - cursor;+ lab6:+ {+ if (!(eq_s_b("e"))) {+ break lab6;+ }+ break lab5;+ }+ cursor = limit - v_7;+ }+ slice_del();+ break lab4;+ }+ cursor = limit - v_6;+ if (!r_undouble()) {+ break lab3;+ }+ }+ break;+ case 2:+ if (!r_R2()) {+ break lab3;+ }+ {+ int v_8 = limit - cursor;+ lab7:+ {+ if (!(eq_s_b("e"))) {+ break lab7;+ }+ break lab3;+ }+ cursor = limit - v_8;+ }+ slice_del();+ break;+ case 3:+ if (!r_R2()) {+ break lab3;+ }+ slice_del();+ if (!r_e_ending()) {+ break lab3;+ }+ break;+ case 4:+ if (!r_R2()) {+ break lab3;+ }+ slice_del();+ break;+ case 5:+ if (!r_R2()) {+ break lab3;+ }+ if (!B_e_found) {+ break lab3;+ }+ slice_del();+ break;+ }+ }+ cursor = limit - v_5;+ int v_9 = limit - cursor;+ lab8:+ {+ if (!(out_grouping_b(g_v_I, 73, 232))) {+ break lab8;+ }+ int v_10 = limit - cursor;+ if (find_among_b(a_5) == 0) {+ break lab8;+ }+ if (!(out_grouping_b(g_v, 97, 232))) {+ break lab8;+ }+ cursor = limit - v_10;+ ket = cursor;+ if (cursor <= limit_backward) {+ break lab8;+ }+ cursor--;+ bra = cursor;+ slice_del();+ }+ cursor = limit - v_9;+ return true;+ }++ @Override+ public boolean stem() {+ int v_1 = cursor;+ r_prelude();+ cursor = v_1;+ int v_2 = cursor;+ r_mark_regions();+ cursor = v_2;+ limit_backward = cursor;+ cursor = limit;+ r_standard_suffix();+ cursor = limit_backward;+ int v_3 = cursor;+ r_postlude();+ cursor = v_3;+ return true;+ }++ @Override+ public boolean equals(Object o) {+ return o instanceof Dutch_porterStemmer;+ }++ @Override+ public int hashCode() {+ return Dutch_porterStemmer.class.getName().hashCode();+ }+}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.javaindex 29ca37d1b3a..19eb2e75da5 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EnglishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from english.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,22 +7,30 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from english.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {- new Among("arsen", -1, -1), new Among("commun", -1, -1), new Among("gener", -1, -1)+ private static final Among[] a_0 = {+ new Among("arsen", -1, -1),+ new Among("commun", -1, -1),+ new Among("emerg", -1, -1),+ new Among("gener", -1, -1),+ new Among("inter", -1, -1),+ new Among("later", -1, -1),+ new Among("organ", -1, -1),+ new Among("past", -1, -1),+ new Among("univers", -1, -1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("'", -1, 1), new Among("'s'", 0, 1), new Among("'s", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ied", -1, 2),new Among("s", -1, 3),new Among("ies", 1, 2),@@ -31,7 +39,31 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("us", 1, -1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {+ new Among("succ", -1, 1), new Among("proc", -1, 1), new Among("exc", -1, 1)+ };++ private static final Among[] a_4 = {+ new Among("even", -1, 2),+ new Among("cann", -1, 2),+ new Among("inn", -1, 2),+ new Among("earr", -1, 2),+ new Among("herr", -1, 2),+ new Among("out", -1, 2),+ new Among("y", -1, 1)+ };++ private static final Among[] a_5 = {+ new Among("", -1, -1),+ new Among("ed", 0, 2),+ new Among("eed", 1, 1),+ new Among("ing", 0, 3),+ new Among("edly", 0, 2),+ new Among("eedly", 4, 1),+ new Among("ingly", 0, 2)+ };++ private static final Among[] a_6 = {new Among("", -1, 3),new Among("bb", 0, 2),new Among("dd", 0, 2),@@ -47,25 +79,16 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("iz", 0, 1)};- private static final Among a_4[] = {- new Among("ed", -1, 2),- new Among("eed", 0, 1),- new Among("ing", -1, 2),- new Among("edly", -1, 2),- new Among("eedly", 3, 1),- new Among("ingly", -1, 2)- };-- private static final Among a_5[] = {+ private static final Among[] a_7 = {new Among("anci", -1, 3),new Among("enci", -1, 2),- new Among("ogi", -1, 13),- new Among("li", -1, 15),+ new Among("ogi", -1, 14),+ new Among("li", -1, 16),new Among("bli", 3, 12),new Among("abli", 4, 4),new Among("alli", 3, 8),new Among("fulli", 3, 9),- new Among("lessli", 3, 14),+ new Among("lessli", 3, 15),new Among("ousli", 3, 10),new Among("entli", 3, 5),new Among("aliti", -1, 8),@@ -80,10 +103,11 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ator", -1, 7),new Among("iveness", -1, 11),new Among("fulness", -1, 9),- new Among("ousness", -1, 10)+ new Among("ousness", -1, 10),+ new Among("ogist", -1, 13)};- private static final Among a_6[] = {+ private static final Among[] a_8 = {new Among("icate", -1, 4),new Among("ative", -1, 6),new Among("alize", -1, 3),@@ -95,7 +119,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ness", -1, 5)};- private static final Among a_7[] = {+ private static final Among[] a_9 = {new Among("ic", -1, 1),new Among("ance", -1, 1),new Among("ence", -1, 1),@@ -116,47 +140,33 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ement", 16, 1)};- private static final Among a_8[] = {new Among("e", -1, 1), new Among("l", -1, 2)};-- private static final Among a_9[] = {- new Among("succeed", -1, -1),- new Among("proceed", -1, -1),- new Among("exceed", -1, -1),- new Among("canning", -1, -1),- new Among("inning", -1, -1),- new Among("earring", -1, -1),- new Among("herring", -1, -1),- new Among("outing", -1, -1)- };+ private static final Among[] a_10 = {new Among("e", -1, 1), new Among("l", -1, 2)};- private static final Among a_10[] = {+ private static final Among[] a_11 = {new Among("andes", -1, -1),new Among("atlas", -1, -1),new Among("bias", -1, -1),new Among("cosmos", -1, -1),- new Among("dying", -1, 3),- new Among("early", -1, 9),- new Among("gently", -1, 7),+ new Among("early", -1, 6),+ new Among("gently", -1, 4),new Among("howe", -1, -1),- new Among("idly", -1, 6),- new Among("lying", -1, 4),+ new Among("idly", -1, 3),new Among("news", -1, -1),- new Among("only", -1, 10),- new Among("singly", -1, 11),+ new Among("only", -1, 7),+ new Among("singly", -1, 8),new Among("skies", -1, 2),new Among("skis", -1, 1),new Among("sky", -1, -1),- new Among("tying", -1, 5),- new Among("ugly", -1, 8)+ new Among("ugly", -1, 5)};- private static final char g_aeo[] = {17, 64};+ private static final char[] g_aeo = {17, 64};- private static final char g_v[] = {17, 65, 16, 1};+ private static final char[] g_v = {17, 65, 16, 1};- private static final char g_v_WXY[] = {1, 17, 65, 208, 1};+ private static final char[] g_v_WXY = {1, 17, 65, 208, 1};- private static final char g_valid_LI[] = {55, 141, 2};+ private static final char[] g_valid_LI = {55, 141, 2};private boolean B_Y_found;private int I_p2;@@ -245,64 +255,24 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {break lab1;}cursor = v_2;- golab3:- while (true) {- lab4:- {- if (!(in_grouping(g_v, 97, 121))) {- break lab4;- }- break golab3;- }- if (cursor >= limit) {- break lab0;- }- cursor++;- }- golab5:- while (true) {- lab6:- {- if (!(out_grouping(g_v, 97, 121))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab0;- }- cursor++;- }- }- I_p1 = cursor;- golab7:- while (true) {- lab8:- {- if (!(in_grouping(g_v, 97, 121))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {+ if (!go_out_grouping(g_v, 97, 121)) {break lab0;}cursor++;- }- golab9:- while (true) {- lab10:- {- if (!(out_grouping(g_v, 97, 121))) {- break lab10;- }- break golab9;- }- if (cursor >= limit) {+ if (!go_in_grouping(g_v, 97, 121)) {break lab0;}cursor++;}+ I_p1 = cursor;+ if (!go_out_grouping(g_v, 97, 121)) {+ break lab0;+ }+ cursor++;+ if (!go_in_grouping(g_v, 97, 121)) {+ break lab0;+ }+ cursor++;I_p2 = cursor;}cursor = v_1;@@ -327,13 +297,21 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {break lab0;}cursor = limit - v_1;- if (!(out_grouping_b(g_v, 97, 121))) {- return false;- }- if (!(in_grouping_b(g_v, 97, 121))) {- return false;+ lab2:+ {+ if (!(out_grouping_b(g_v, 97, 121))) {+ break lab2;+ }+ if (!(in_grouping_b(g_v, 97, 121))) {+ break lab2;+ }+ if (cursor > limit_backward) {+ break lab2;+ }+ break lab0;}- if (cursor > limit_backward) {+ cursor = limit - v_1;+ if (!(eq_s_b("past"))) {return false;}}@@ -396,20 +374,10 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}cursor--;- golab3:- while (true) {- lab4:- {- if (!(in_grouping_b(g_v, 97, 121))) {- break lab4;- }- break golab3;- }- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_v, 97, 121)) {+ return false;}+ cursor--;slice_del();break;}@@ -419,81 +387,122 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Step_1b() {int among_var;ket = cursor;- among_var = find_among_b(a_4);- if (among_var == 0) {- return false;- }+ among_var = find_among_b(a_5);bra = cursor;- switch (among_var) {- case 1:- if (!r_R1()) {- return false;- }- slice_from("ee");- break;- case 2:- int v_1 = limit - cursor;- golab0:- while (true) {- lab1:- {- if (!(in_grouping_b(g_v, 97, 121))) {- break lab1;- }- break golab0;- }- if (cursor <= limit_backward) {- return false;- }- cursor--;- }- cursor = limit - v_1;- slice_del();- ket = cursor;- bra = cursor;- int v_3 = limit - cursor;- among_var = find_among_b(a_3);+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {switch (among_var) {case 1:- slice_from("e");- return false;- case 2:+ int v_2 = limit - cursor;+ lab2:{- int v_4 = limit - cursor;- lab2:+ if (!r_R1()) {+ break lab2;+ }+ lab3:{- if (!(in_grouping_b(g_aeo, 97, 111))) {- break lab2;+ int v_3 = limit - cursor;+ lab4:+ {+ if (find_among_b(a_3) == 0) {+ break lab4;+ }+ if (cursor > limit_backward) {+ break lab4;+ }+ break lab3;}- if (cursor > limit_backward) {- break lab2;- }- return false;+ cursor = limit - v_3;+ slice_from("ee");}- cursor = limit - v_4;}+ cursor = limit - v_2;break;+ case 2:+ break lab1;case 3:- if (cursor != I_p1) {- return false;+ among_var = find_among_b(a_4);+ if (among_var == 0) {+ break lab1;+ }+ switch (among_var) {+ case 1:+ int v_4 = limit - cursor;+ if (!(out_grouping_b(g_v, 97, 121))) {+ break lab1;+ }+ if (cursor > limit_backward) {+ break lab1;+ }+ cursor = limit - v_4;+ bra = cursor;+ slice_from("ie");+ break;+ case 2:+ if (cursor > limit_backward) {+ break lab1;+ }+ break;}- int v_5 = limit - cursor;- if (!r_shortv()) {+ break;+ }+ break lab0;+ }+ cursor = limit - v_1;+ int v_5 = limit - cursor;+ if (!go_out_grouping_b(g_v, 97, 121)) {+ return false;+ }+ cursor--;+ cursor = limit - v_5;+ slice_del();+ ket = cursor;+ bra = cursor;+ int v_6 = limit - cursor;+ among_var = find_among_b(a_6);+ switch (among_var) {+ case 1:+ slice_from("e");+ return false;+ case 2:+ {+ int v_7 = limit - cursor;+ lab5:+ {+ if (!(in_grouping_b(g_aeo, 97, 111))) {+ break lab5;+ }+ if (cursor > limit_backward) {+ break lab5;+ }return false;}- cursor = limit - v_5;- slice_from("e");+ cursor = limit - v_7;+ }+ break;+ case 3:+ if (cursor != I_p1) {return false;- }- cursor = limit - v_3;- ket = cursor;- if (cursor <= limit_backward) {+ }+ int v_8 = limit - cursor;+ if (!r_shortv()) {+ return false;+ }+ cursor = limit - v_8;+ slice_from("e");return false;- }- cursor--;- bra = cursor;- slice_del();- break;+ }+ cursor = limit - v_6;+ ket = cursor;+ if (cursor <= limit_backward) {+ return false;+ }+ cursor--;+ bra = cursor;+ slice_del();}return true;}@@ -533,7 +542,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Step_2() {int among_var;ket = cursor;- among_var = find_among_b(a_5);+ among_var = find_among_b(a_7);if (among_var == 0) {return false;}@@ -579,15 +588,18 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("ble");break;case 13:+ slice_from("og");+ break;+ case 14:if (!(eq_s_b("l"))) {return false;}slice_from("og");break;- case 14:+ case 15:slice_from("less");break;- case 15:+ case 16:if (!(in_grouping_b(g_valid_LI, 99, 116))) {return false;}@@ -600,7 +612,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Step_3() {int among_var;ket = cursor;- among_var = find_among_b(a_6);+ among_var = find_among_b(a_8);if (among_var == 0) {return false;}@@ -637,7 +649,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Step_4() {int among_var;ket = cursor;- among_var = find_among_b(a_7);+ among_var = find_among_b(a_9);if (among_var == 0) {return false;}@@ -674,7 +686,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_Step_5() {int among_var;ket = cursor;- among_var = find_among_b(a_8);+ among_var = find_among_b(a_10);if (among_var == 0) {return false;}@@ -683,7 +695,6 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {case 1:lab0:{- int v_1 = limit - cursor;lab1:{if (!r_R2()) {@@ -691,12 +702,11 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab0;}- cursor = limit - v_1;if (!r_R1()) {return false;}{- int v_2 = limit - cursor;+ int v_1 = limit - cursor;lab2:{if (!r_shortv()) {@@ -704,7 +714,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_2;+ cursor = limit - v_1;}}slice_del();@@ -722,22 +732,10 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_exception2() {- ket = cursor;- if (find_among_b(a_9) == 0) {- return false;- }- bra = cursor;- if (cursor > limit_backward) {- return false;- }- return true;- }-private boolean r_exception1() {int among_var;bra = cursor;- among_var = find_among(a_10);+ among_var = find_among(a_11);if (among_var == 0) {return false;}@@ -753,30 +751,21 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("sky");break;case 3:- slice_from("die");- break;- case 4:- slice_from("lie");- break;- case 5:- slice_from("tie");- break;- case 6:slice_from("idl");break;- case 7:+ case 4:slice_from("gentl");break;- case 8:+ case 5:slice_from("ugli");break;- case 9:+ case 6:slice_from("earli");break;- case 10:+ case 7:slice_from("onli");break;- case 11:+ case 8:slice_from("singl");break;}@@ -784,7 +773,7 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_postlude() {- if (!(B_Y_found)) {+ if (!B_Y_found) {return false;}while (true) {@@ -856,43 +845,31 @@ public class EnglishStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_5 = limit - cursor;+ int v_3 = limit - cursor;r_Step_1a();+ cursor = limit - v_3;+ int v_4 = limit - cursor;+ r_Step_1b();+ cursor = limit - v_4;+ int v_5 = limit - cursor;+ r_Step_1c();cursor = limit - v_5;- lab4:- {- int v_6 = limit - cursor;- lab5:- {- if (!r_exception2()) {- break lab5;- }- break lab4;- }- cursor = limit - v_6;- int v_7 = limit - cursor;- r_Step_1b();- cursor = limit - v_7;- int v_8 = limit - cursor;- r_Step_1c();- cursor = limit - v_8;- int v_9 = limit - cursor;- r_Step_2();- cursor = limit - v_9;- int v_10 = limit - cursor;- r_Step_3();- cursor = limit - v_10;- int v_11 = limit - cursor;- r_Step_4();- cursor = limit - v_11;- int v_12 = limit - cursor;- r_Step_5();- cursor = limit - v_12;- }+ int v_6 = limit - cursor;+ r_Step_2();+ cursor = limit - v_6;+ int v_7 = limit - cursor;+ r_Step_3();+ cursor = limit - v_7;+ int v_8 = limit - cursor;+ r_Step_4();+ cursor = limit - v_8;+ int v_9 = limit - cursor;+ r_Step_5();+ cursor = limit - v_9;cursor = limit_backward;- int v_13 = cursor;+ int v_10 = cursor;r_postlude();- cursor = v_13;+ cursor = v_10;}return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EsperantoStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EsperantoStemmer.javanew file mode 100644index 00000000000..f78d5aa059e--- /dev/null+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EsperantoStemmer.java@@ -0,0 +1,671 @@+// Generated from esperanto.sbl by Snowball 3.0.0 - https://snowballstem.org/++package org.tartarus.snowball.ext;++import org.tartarus.snowball.Among;++/**+ * This class implements the stemming algorithm defined by a snowball script.+ *+ * <p>Generated from esperanto.sbl by Snowball 3.0.0 - https://snowballstem.org/+ */+@SuppressWarnings("unused")+public class EsperantoStemmer extends org.tartarus.snowball.SnowballStemmer {++ private static final long serialVersionUID = 1L;++ private static final Among[] a_0 = {+ new Among("", -1, 14),+ new Among("-", 0, 13),+ new Among("cx", 0, 1),+ new Among("gx", 0, 2),+ new Among("hx", 0, 3),+ new Among("jx", 0, 4),+ new Among("q", 0, 12),+ new Among("sx", 0, 5),+ new Among("ux", 0, 6),+ new Among("w", 0, 12),+ new Among("x", 0, 12),+ new Among("y", 0, 12),+ new Among("\u00E1", 0, 7),+ new Among("\u00E9", 0, 8),+ new Among("\u00ED", 0, 9),+ new Among("\u00F3", 0, 10),+ new Among("\u00FA", 0, 11)+ };++ private static final Among[] a_1 = {+ new Among("as", -1, -1),+ new Among("i", -1, -1),+ new Among("is", 1, -1),+ new Among("os", -1, -1),+ new Among("u", -1, -1),+ new Among("us", 4, -1)+ };++ private static final Among[] a_2 = {+ new Among("ci", -1, -1),+ new Among("gi", -1, -1),+ new Among("hi", -1, -1),+ new Among("li", -1, -1),+ new Among("ili", 3, -1),+ new Among("\u015Dli", 3, -1),+ new Among("mi", -1, -1),+ new Among("ni", -1, -1),+ new Among("oni", 7, -1),+ new Among("ri", -1, -1),+ new Among("si", -1, -1),+ new Among("vi", -1, -1),+ new Among("ivi", 11, -1),+ new Among("\u011Di", -1, -1),+ new Among("\u015Di", -1, -1),+ new Among("i\u015Di", 14, -1),+ new Among("mal\u015Di", 14, -1)+ };++ private static final Among[] a_3 = {+ new Among("amb", -1, -1),+ new Among("bald", -1, -1),+ new Among("malbald", 1, -1),+ new Among("morg", -1, -1),+ new Among("postmorg", 3, -1),+ new Among("adi", -1, -1),+ new Among("hodi", -1, -1),+ new Among("ank", -1, -1),+ new Among("\u0109irk", -1, -1),+ new Among("tut\u0109irk", 8, -1),+ new Among("presk", -1, -1),+ new Among("almen", -1, -1),+ new Among("apen", -1, -1),+ new Among("hier", -1, -1),+ new Among("anta\u016Dhier", 13, -1),+ new Among("malgr", -1, -1),+ new Among("ankor", -1, -1),+ new Among("kontr", -1, -1),+ new Among("anstat", -1, -1),+ new Among("kvaz", -1, -1)+ };++ private static final Among[] a_4 = {new Among("aliu", -1, -1), new Among("unu", -1, -1)};++ private static final Among[] a_5 = {+ new Among("aha", -1, -1),+ new Among("haha", 0, -1),+ new Among("haleluja", -1, -1),+ new Among("hola", -1, -1),+ new Among("hosana", -1, -1),+ new Among("maltra", -1, -1),+ new Among("hura", -1, -1),+ new Among("\u0125a\u0125a", -1, -1),+ new Among("ekde", -1, -1),+ new Among("elde", -1, -1),+ new Among("disde", -1, -1),+ new Among("ehe", -1, -1),+ new Among("maltre", -1, -1),+ new Among("dirlididi", -1, -1),+ new Among("malpli", -1, -1),+ new Among("mal\u0109i", -1, -1),+ new Among("malkaj", -1, -1),+ new Among("amen", -1, -1),+ new Among("tamen", 17, -1),+ new Among("oho", -1, -1),+ new Among("maltro", -1, -1),+ new Among("minus", -1, -1),+ new Among("uhu", -1, -1),+ new Among("muu", -1, -1)+ };++ private static final Among[] a_6 = {+ new Among("tri", -1, -1), new Among("du", -1, -1), new Among("unu", -1, -1)+ };++ private static final Among[] a_7 = {new Among("dek", -1, -1), new Among("cent", -1, -1)};++ private static final Among[] a_8 = {+ new Among("k", -1, -1),+ new Among("kelk", 0, -1),+ new Among("nen", -1, -1),+ new Among("t", -1, -1),+ new Among("mult", 3, -1),+ new Among("samt", 3, -1),+ new Among("\u0109", -1, -1)+ };++ private static final Among[] a_9 = {+ new Among("a", -1, -1),+ new Among("e", -1, -1),+ new Among("i", -1, -1),+ new Among("j", -1, 1),+ new Among("aj", 3, -1),+ new Among("oj", 3, -1),+ new Among("n", -1, 1),+ new Among("an", 6, -1),+ new Among("en", 6, -1),+ new Among("jn", 6, 1),+ new Among("ajn", 9, -1),+ new Among("ojn", 9, -1),+ new Among("on", 6, -1),+ new Among("o", -1, -1),+ new Among("as", -1, -1),+ new Among("is", -1, -1),+ new Among("os", -1, -1),+ new Among("us", -1, -1),+ new Among("u", -1, -1)+ };++ private static final char[] g_vowel = {17, 65, 16};++ private static final char[] g_aou = {1, 64, 16};++ private static final char[] g_digit = {255, 3};++ private boolean r_canonical_form() {+ boolean B_foreign;+ int among_var;+ B_foreign = false;+ while (true) {+ int v_1 = cursor;+ lab0:+ {+ bra = cursor;+ among_var = find_among(a_0);+ ket = cursor;+ switch (among_var) {+ case 1:+ slice_from("\u0109");+ break;+ case 2:+ slice_from("\u011D");+ break;+ case 3:+ slice_from("\u0125");+ break;+ case 4:+ slice_from("\u0135");+ break;+ case 5:+ slice_from("\u015D");+ break;+ case 6:+ slice_from("\u016D");+ break;+ case 7:+ slice_from("a");+ B_foreign = true;+ break;+ case 8:+ slice_from("e");+ B_foreign = true;+ break;+ case 9:+ slice_from("i");+ B_foreign = true;+ break;+ case 10:+ slice_from("o");+ B_foreign = true;+ break;+ case 11:+ slice_from("u");+ B_foreign = true;+ break;+ case 12:+ B_foreign = true;+ break;+ case 13:+ B_foreign = false;+ break;+ case 14:+ if (cursor >= limit) {+ break lab0;+ }+ cursor++;+ break;+ }+ continue;+ }+ cursor = v_1;+ break;+ }+ return !B_foreign;+ }++ private boolean r_initial_apostrophe() {+ bra = cursor;+ if (!(eq_s("'"))) {+ return false;+ }+ ket = cursor;+ if (!(eq_s("st"))) {+ return false;+ }+ if (find_among(a_1) == 0) {+ return false;+ }+ if (cursor < limit) {+ return false;+ }+ slice_from("e");+ return true;+ }++ private boolean r_pronoun() {+ ket = cursor;+ int v_1 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("n"))) {+ cursor = limit - v_1;+ break lab0;+ }+ }+ bra = cursor;+ if (find_among_b(a_2) == 0) {+ return false;+ }+ lab1:+ {+ int v_2 = limit - cursor;+ lab2:+ {+ if (cursor > limit_backward) {+ break lab2;+ }+ break lab1;+ }+ cursor = limit - v_2;+ if (!(eq_s_b("-"))) {+ return false;+ }+ }+ slice_del();+ return true;+ }++ private boolean r_final_apostrophe() {+ ket = cursor;+ if (!(eq_s_b("'"))) {+ return false;+ }+ bra = cursor;+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("l"))) {+ break lab1;+ }+ if (cursor > limit_backward) {+ break lab1;+ }+ slice_from("a");+ break lab0;+ }+ cursor = limit - v_1;+ lab2:+ {+ if (!(eq_s_b("un"))) {+ break lab2;+ }+ if (cursor > limit_backward) {+ break lab2;+ }+ slice_from("u");+ break lab0;+ }+ cursor = limit - v_1;+ lab3:+ {+ if (find_among_b(a_3) == 0) {+ break lab3;+ }+ lab4:+ {+ int v_2 = limit - cursor;+ lab5:+ {+ if (cursor > limit_backward) {+ break lab5;+ }+ break lab4;+ }+ cursor = limit - v_2;+ if (!(eq_s_b("-"))) {+ break lab3;+ }+ }+ slice_from("a\u016D");+ break lab0;+ }+ cursor = limit - v_1;+ slice_from("o");+ }+ return true;+ }++ private boolean r_ujn_suffix() {+ ket = cursor;+ int v_1 = limit - cursor;+ lab0:+ {+ if (!(eq_s_b("n"))) {+ cursor = limit - v_1;+ break lab0;+ }+ }+ int v_2 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("j"))) {+ cursor = limit - v_2;+ break lab1;+ }+ }+ bra = cursor;+ if (find_among_b(a_4) == 0) {+ return false;+ }+ lab2:+ {+ int v_3 = limit - cursor;+ lab3:+ {+ if (cursor > limit_backward) {+ break lab3;+ }+ break lab2;+ }+ cursor = limit - v_3;+ if (!(eq_s_b("-"))) {+ return false;+ }+ }+ slice_del();+ return true;+ }++ private boolean r_uninflected() {+ if (find_among_b(a_5) == 0) {+ return false;+ }+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ if (cursor > limit_backward) {+ break lab1;+ }+ break lab0;+ }+ cursor = limit - v_1;+ if (!(eq_s_b("-"))) {+ return false;+ }+ }+ return true;+ }++ private boolean r_merged_numeral() {+ if (find_among_b(a_6) == 0) {+ return false;+ }+ return find_among_b(a_7) != 0;+ }++ private boolean r_correlative() {+ ket = cursor;+ bra = cursor;+ int v_1 = limit - cursor;+ lab0:+ {+ int v_2 = limit - cursor;+ lab1:+ {+ int v_3 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("n"))) {+ cursor = limit - v_3;+ break lab2;+ }+ }+ bra = cursor;+ if (!(eq_s_b("e"))) {+ break lab1;+ }+ break lab0;+ }+ cursor = limit - v_2;+ int v_4 = limit - cursor;+ lab3:+ {+ if (!(eq_s_b("n"))) {+ cursor = limit - v_4;+ break lab3;+ }+ }+ int v_5 = limit - cursor;+ lab4:+ {+ if (!(eq_s_b("j"))) {+ cursor = limit - v_5;+ break lab4;+ }+ }+ bra = cursor;+ if (!(in_grouping_b(g_aou, 97, 117))) {+ return false;+ }+ }+ if (!(eq_s_b("i"))) {+ return false;+ }+ int v_6 = limit - cursor;+ lab5:+ {+ if (find_among_b(a_8) == 0) {+ cursor = limit - v_6;+ break lab5;+ }+ }+ lab6:+ {+ int v_7 = limit - cursor;+ lab7:+ {+ if (cursor > limit_backward) {+ break lab7;+ }+ break lab6;+ }+ cursor = limit - v_7;+ if (!(eq_s_b("-"))) {+ return false;+ }+ }+ cursor = limit - v_1;+ slice_del();+ return true;+ }++ private boolean r_long_word() {+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ for (int v_2 = 2; v_2 > 0; v_2--) {+ if (!go_out_grouping_b(g_vowel, 97, 117)) {+ break lab1;+ }+ cursor--;+ }+ break lab0;+ }+ cursor = limit - v_1;+ lab2:+ {+ golab3:+ while (true) {+ lab4:+ {+ if (!(eq_s_b("-"))) {+ break lab4;+ }+ break golab3;+ }+ if (cursor <= limit_backward) {+ break lab2;+ }+ cursor--;+ }+ if (cursor <= limit_backward) {+ break lab2;+ }+ cursor--;+ break lab0;+ }+ cursor = limit - v_1;+ if (!go_out_grouping_b(g_digit, 48, 57)) {+ return false;+ }+ cursor--;+ }+ return true;+ }++ private boolean r_standard_suffix() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_9);+ if (among_var == 0) {+ return false;+ }+ switch (among_var) {+ case 1:+ int v_1 = limit - cursor;+ lab0:+ {+ int v_2 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("-"))) {+ break lab1;+ }+ break lab0;+ }+ cursor = limit - v_2;+ if (!(in_grouping_b(g_digit, 48, 57))) {+ return false;+ }+ }+ cursor = limit - v_1;+ break;+ }+ int v_3 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("-"))) {+ cursor = limit - v_3;+ break lab2;+ }+ }+ bra = cursor;+ slice_del();+ return true;+ }++ @Override+ public boolean stem() {+ int v_1 = cursor;+ if (!r_canonical_form()) {+ return false;+ }+ cursor = v_1;+ int v_2 = cursor;+ r_initial_apostrophe();+ cursor = v_2;+ limit_backward = cursor;+ cursor = limit;+ {+ int v_3 = limit - cursor;+ lab0:+ {+ if (!r_pronoun()) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_3;+ }+ int v_4 = limit - cursor;+ r_final_apostrophe();+ cursor = limit - v_4;+ {+ int v_5 = limit - cursor;+ lab1:+ {+ if (!r_correlative()) {+ break lab1;+ }+ return false;+ }+ cursor = limit - v_5;+ }+ {+ int v_6 = limit - cursor;+ lab2:+ {+ if (!r_uninflected()) {+ break lab2;+ }+ return false;+ }+ cursor = limit - v_6;+ }+ {+ int v_7 = limit - cursor;+ lab3:+ {+ if (!r_merged_numeral()) {+ break lab3;+ }+ return false;+ }+ cursor = limit - v_7;+ }+ {+ int v_8 = limit - cursor;+ lab4:+ {+ if (!r_ujn_suffix()) {+ break lab4;+ }+ return false;+ }+ cursor = limit - v_8;+ }+ int v_9 = limit - cursor;+ if (!r_long_word()) {+ return false;+ }+ cursor = limit - v_9;+ if (!r_standard_suffix()) {+ return false;+ }+ cursor = limit_backward;+ return true;+ }++ @Override+ public boolean equals(Object o) {+ return o instanceof EsperantoStemmer;+ }++ @Override+ public int hashCode() {+ return EsperantoStemmer.class.getName().hashCode();+ }+}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.javaindex 29b78ef35e9..2f95e9f3490 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/EstonianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from estonian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,16 +7,16 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from estonian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {new Among("gi", -1, 1), new Among("ki", -1, 2)};+ private static final Among[] a_0 = {new Among("gi", -1, 1), new Among("ki", -1, 2)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("da", -1, 3),new Among("mata", -1, 1),new Among("b", -1, 3),@@ -40,7 +40,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("taks", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("aa", -1, -1),new Among("ee", -1, -1),new Among("ii", -1, -1),@@ -52,9 +52,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00FC\u00FC", -1, -1)};- private static final Among a_3[] = {new Among("i", -1, 1)};-- private static final Among a_4[] = {+ private static final Among[] a_3 = {new Among("lane", -1, 1),new Among("line", -1, 3),new Among("mine", -1, 2),@@ -69,7 +67,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("mist", -1, 2)};- private static final Among a_5[] = {+ private static final Among[] a_4 = {new Among("ga", -1, 1),new Among("ta", -1, 1),new Among("le", -1, 1),@@ -82,7 +80,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("st", 7, 1)};- private static final Among a_6[] = {+ private static final Among[] a_5 = {new Among("", -1, 2),new Among("las", 0, 1),new Among("lis", 0, 1),@@ -90,7 +88,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("t", 0, -1)};- private static final Among a_7[] = {+ private static final Among[] a_6 = {new Among("d", -1, 4),new Among("sid", 0, 2),new Among("de", -1, 4),@@ -100,22 +98,22 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("te", -1, 3)};- private static final Among a_8[] = {+ private static final Among[] a_7 = {new Among("va", -1, -1),new Among("du", -1, -1),new Among("nu", -1, -1),new Among("tu", -1, -1)};- private static final Among a_9[] = {+ private static final Among[] a_8 = {new Among("kk", -1, 1), new Among("pp", -1, 2), new Among("tt", -1, 3)};- private static final Among a_10[] = {+ private static final Among[] a_9 = {new Among("ma", -1, 2), new Among("mai", -1, 1), new Among("m", -1, 1)};- private static final Among a_11[] = {+ private static final Among[] a_10 = {new Among("joob", -1, 1),new Among("jood", -1, 1),new Among("joodakse", 1, 1),@@ -408,18 +406,18 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("v\u00F5ivad", -1, 11)};- private static final char g_V1[] = {+ private static final char[] g_V1 = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 48, 8};- private static final char g_RV[] = {17, 65, 16};+ private static final char[] g_RV = {17, 65, 16};- private static final char g_KI[] = {+ private static final char[] g_KI = {117, 66, 6, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,128, 0, 0, 0, 16};- private static final char g_GI[] = {+ private static final char[] g_GI = {21, 123, 243, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 48, 8};@@ -427,37 +425,14 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_mark_regions() {I_p1 = limit;- golab0:- while (true) {- int v_1 = cursor;- lab1:- {- if (!(in_grouping(g_V1, 97, 252))) {- break lab1;- }- cursor = v_1;- break golab0;- }- cursor = v_1;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_V1, 97, 252)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_V1, 97, 252))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_V1, 97, 252)) {+ return false;}+ cursor++;I_p1 = cursor;return true;}@@ -467,17 +442,17 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_0);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;- int v_3 = limit - cursor;+ limit_backward = v_1;+ int v_2 = limit - cursor;{int c = cursor - 4;if (c < limit_backward) {@@ -485,16 +460,16 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor = c;}- cursor = limit - v_3;+ cursor = limit - v_2;switch (among_var) {case 1:- int v_4 = limit - cursor;+ int v_3 = limit - cursor;if (!(in_grouping_b(g_GI, 97, 252))) {return false;}- cursor = limit - v_4;+ cursor = limit - v_3;{- int v_5 = limit - cursor;+ int v_4 = limit - cursor;lab0:{if (!r_LONGV()) {@@ -502,7 +477,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_5;+ cursor = limit - v_4;}slice_del();break;@@ -521,16 +496,16 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_1);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_del();@@ -549,25 +524,22 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_LONGV() {- if (find_among_b(a_2) == 0) {- return false;- }- return true;+ return find_among_b(a_2) != 0;}private boolean r_i_plural() {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- if (find_among_b(a_3) == 0) {- limit_backward = v_2;+ if (!(eq_s_b("i"))) {+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;if (!(in_grouping_b(g_RV, 97, 117))) {return false;}@@ -580,16 +552,16 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_4);+ among_var = find_among_b(a_3);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_from("lase");@@ -609,21 +581,21 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_5);+ among_var = find_among_b(a_4);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:lab0:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab1:{if (!(in_grouping_b(g_RV, 97, 117))) {@@ -631,14 +603,14 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab0;}- cursor = limit - v_3;+ cursor = limit - v_2;if (!r_LONGV()) {return false;}}break;case 2:- int v_4 = limit - cursor;+ int v_3 = limit - cursor;{int c = cursor - 4;if (c < limit_backward) {@@ -646,7 +618,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor = c;}- cursor = limit - v_4;+ cursor = limit - v_3;break;}slice_del();@@ -658,23 +630,23 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_7);+ among_var = find_among_b(a_6);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_from("iku");break;case 2:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{if (!r_LONGV()) {@@ -682,17 +654,17 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_3;+ cursor = limit - v_2;}slice_del();break;case 3:lab1:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab2:{- int v_5 = limit - cursor;+ int v_4 = limit - cursor;{int c = cursor - 4;if (c < limit_backward) {@@ -700,8 +672,8 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor = c;}- cursor = limit - v_5;- among_var = find_among_b(a_6);+ cursor = limit - v_4;+ among_var = find_among_b(a_5);switch (among_var) {case 1:slice_from("e");@@ -712,14 +684,14 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;slice_from("t");}break;case 4:lab3:{- int v_6 = limit - cursor;+ int v_5 = limit - cursor;lab4:{if (!(in_grouping_b(g_RV, 97, 117))) {@@ -727,7 +699,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_6;+ cursor = limit - v_5;if (!r_LONGV()) {return false;}@@ -742,15 +714,15 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- if (find_among_b(a_8) == 0) {- limit_backward = v_2;+ if (find_among_b(a_7) == 0) {+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;slice_del();return true;}@@ -764,7 +736,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}ket = cursor;- among_var = find_among_b(a_9);+ among_var = find_among_b(a_8);if (among_var == 0) {return false;}@@ -788,16 +760,16 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_10);+ among_var = find_among_b(a_9);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:if (!(in_grouping_b(g_RV, 97, 117))) {@@ -837,7 +809,7 @@ public class EstonianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_verb_exceptions() {int among_var;bra = cursor;- among_var = find_among(a_11);+ among_var = find_among(a_10);if (among_var == 0) {return false;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.javaindex 4c26766295b..1ff3c235d3b 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FinnishStemmer.java@@ -1,13 +1,15 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from finnish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;+import java.util.Arrays;import org.tartarus.snowball.Among;+import org.tartarus.snowball.CharArraySequence;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from finnish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {@@ -16,7 +18,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final java.lang.invoke.MethodHandles.Lookup methodObject =java.lang.invoke.MethodHandles.lookup();- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("pa", -1, 1),new Among("sti", -1, 2),new Among("kaan", -1, 1),@@ -29,7 +31,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("k\u00F6", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("lla", -1, -1),new Among("na", -1, -1),new Among("ssa", -1, -1),@@ -38,7 +40,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("sta", 3, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ll\u00E4", -1, -1),new Among("n\u00E4", -1, -1),new Among("ss\u00E4", -1, -1),@@ -47,9 +49,9 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("st\u00E4", 3, -1)};- private static final Among a_3[] = {new Among("lle", -1, -1), new Among("ine", -1, -1)};+ private static final Among[] a_3 = {new Among("lle", -1, -1), new Among("ine", -1, -1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("nsa", -1, 3),new Among("mme", -1, 3),new Among("nne", -1, 3),@@ -61,7 +63,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ns\u00E4", -1, 3)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("aa", -1, -1),new Among("ee", -1, -1),new Among("ii", -1, -1),@@ -71,7 +73,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F6\u00F6", -1, -1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("a", -1, 8),new Among("lla", 0, -1),new Among("na", 0, -1),@@ -104,7 +106,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("tt\u00E4", 26, 2)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("eja", -1, -1),new Among("mma", -1, 1),new Among("imma", 1, -1),@@ -121,93 +123,48 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("imp\u00E4", 12, -1)};- private static final Among a_8[] = {new Among("i", -1, -1), new Among("j", -1, -1)};+ private static final Among[] a_8 = {new Among("i", -1, -1), new Among("j", -1, -1)};- private static final Among a_9[] = {new Among("mma", -1, 1), new Among("imma", 0, -1)};+ private static final Among[] a_9 = {new Among("mma", -1, 1), new Among("imma", 0, -1)};- private static final char g_AEI[] = {17, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8};+ private static final char[] g_AEI = {17, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8};- private static final char g_C[] = {119, 223, 119, 1};+ private static final char[] g_C = {119, 223, 119, 1};- private static final char g_V1[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32};+ private static final char[] g_V1 = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32};- private static final char g_V2[] = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32};+ private static final char[] g_V2 = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32};- private static final char g_particle_end[] = {+ private static final char[] g_particle_end = {17, 97, 24, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32};private boolean B_ending_removed;- private java.lang.StringBuilder S_x = new java.lang.StringBuilder();+ private char[] S_x = new char[8];+ private int LS_x = 0;private int I_p2;private int I_p1;private boolean r_mark_regions() {I_p1 = limit;I_p2 = limit;- golab0:- while (true) {- int v_1 = cursor;- lab1:- {- if (!(in_grouping(g_V1, 97, 246))) {- break lab1;- }- cursor = v_1;- break golab0;- }- cursor = v_1;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_V1, 97, 246)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_V1, 97, 246))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_V1, 97, 246)) {+ return false;}+ cursor++;I_p1 = cursor;- golab4:- while (true) {- int v_3 = cursor;- lab5:- {- if (!(in_grouping(g_V1, 97, 246))) {- break lab5;- }- cursor = v_3;- break golab4;- }- cursor = v_3;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_V1, 97, 246)) {+ return false;}- golab6:- while (true) {- lab7:- {- if (!(out_grouping(g_V1, 97, 246))) {- break lab7;- }- break golab6;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_V1, 97, 246)) {+ return false;}+ cursor++;I_p2 = cursor;return true;}@@ -221,16 +178,16 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_0);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:if (!(in_grouping_b(g_particle_end, 97, 246))) {@@ -252,20 +209,20 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_4);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{if (!(eq_s_b("k"))) {@@ -273,7 +230,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_3;+ cursor = limit - v_2;}slice_del();break;@@ -311,21 +268,15 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- public boolean r_LONG() {- if (find_among_b(a_5) == 0) {- return false;- }- return true;+ private boolean r_LONG() {+ return find_among_b(a_5) != 0;}- public boolean r_VI() {+ private boolean r_VI() {if (!(eq_s_b("i"))) {return false;}- if (!(in_grouping_b(g_V2, 97, 246))) {- return false;- }- return true;+ return in_grouping_b(g_V2, 97, 246);}private boolean r_case_ending() {@@ -333,16 +284,16 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;among_var = find_among_b(a_6);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:if (!(eq_s_b("a"))) {@@ -375,13 +326,13 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}break;case 7:- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab1:{- int v_5 = limit - cursor;+ int v_4 = limit - cursor;lab2:{if (!r_LONG()) {@@ -389,15 +340,15 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_5;+ cursor = limit - v_4;if (!(eq_s_b("ie"))) {- cursor = limit - v_3;+ cursor = limit - v_2;break lab0;}}- cursor = limit - v_4;+ cursor = limit - v_3;if (cursor <= limit_backward) {- cursor = limit - v_3;+ cursor = limit - v_2;break lab0;}cursor--;@@ -423,20 +374,20 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p2) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p2;ket = cursor;among_var = find_among_b(a_7);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{if (!(eq_s_b("po"))) {@@ -444,7 +395,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_3;+ cursor = limit - v_2;}break;}@@ -456,15 +407,15 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;if (find_among_b(a_8) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;slice_del();return true;}@@ -474,39 +425,39 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;if (!(eq_s_b("t"))) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- int v_3 = limit - cursor;+ int v_2 = limit - cursor;if (!(in_grouping_b(g_V1, 97, 246))) {- limit_backward = v_2;+ limit_backward = v_1;return false;}- cursor = limit - v_3;+ cursor = limit - v_2;slice_del();- limit_backward = v_2;+ limit_backward = v_1;if (cursor < I_p2) {return false;}- int v_5 = limit_backward;+ int v_3 = limit_backward;limit_backward = I_p2;ket = cursor;among_var = find_among_b(a_9);if (among_var == 0) {- limit_backward = v_5;+ limit_backward = v_3;return false;}bra = cursor;- limit_backward = v_5;+ limit_backward = v_3;switch (among_var) {case 1:{- int v_6 = limit - cursor;+ int v_4 = limit - cursor;lab0:{if (!(eq_s_b("po"))) {@@ -514,7 +465,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_6;+ cursor = limit - v_4;}break;}@@ -526,16 +477,16 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;if (!r_LONG()) {break lab0;}- cursor = limit - v_4;+ cursor = limit - v_3;ket = cursor;if (cursor <= limit_backward) {break lab0;@@ -544,8 +495,8 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {bra = cursor;slice_del();}- cursor = limit - v_3;- int v_5 = limit - cursor;+ cursor = limit - v_2;+ int v_4 = limit - cursor;lab1:{ket = cursor;@@ -558,8 +509,8 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();}- cursor = limit - v_5;- int v_6 = limit - cursor;+ cursor = limit - v_4;+ int v_5 = limit - cursor;lab2:{ket = cursor;@@ -569,7 +520,7 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {bra = cursor;lab3:{- int v_7 = limit - cursor;+ int v_6 = limit - cursor;lab4:{if (!(eq_s_b("o"))) {@@ -577,15 +528,15 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_7;+ cursor = limit - v_6;if (!(eq_s_b("u"))) {break lab2;}}slice_del();}- cursor = limit - v_6;- int v_8 = limit - cursor;+ cursor = limit - v_5;+ int v_7 = limit - cursor;lab5:{ket = cursor;@@ -598,32 +549,24 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();}- cursor = limit - v_8;- limit_backward = v_2;- golab6:- while (true) {- int v_9 = limit - cursor;- lab7:- {- if (!(out_grouping_b(g_V1, 97, 246))) {- break lab7;- }- cursor = limit - v_9;- break golab6;- }- cursor = limit - v_9;- if (cursor <= limit_backward) {- return false;- }- cursor--;+ cursor = limit - v_7;+ limit_backward = v_1;+ if (!go_in_grouping_b(g_V1, 97, 246)) {+ return false;}ket = cursor;if (!(in_grouping_b(g_C, 98, 122))) {return false;}bra = cursor;- slice_to(S_x);- if (!(eq_s_b(S_x))) {+ slice_check();+ if (S_x.length < ket - bra) {+ S_x = Arrays.copyOfRange(current, bra, ket);+ } else {+ System.arraycopy(current, bra, S_x, 0, ket - bra);+ }+ LS_x = ket - bra;+ if (!(eq_s_b(new CharArraySequence(S_x, LS_x)))) {return false;}slice_del();@@ -654,21 +597,21 @@ public class FinnishStemmer extends org.tartarus.snowball.SnowballStemmer {{lab1:{- if (!(B_ending_removed)) {+ if (!B_ending_removed) {break lab1;}- int v_7 = limit - cursor;+ int v_6 = limit - cursor;r_i_plural();- cursor = limit - v_7;+ cursor = limit - v_6;break lab0;}- int v_8 = limit - cursor;+ int v_7 = limit - cursor;r_t_plural();- cursor = limit - v_8;+ cursor = limit - v_7;}- int v_9 = limit - cursor;+ int v_8 = limit - cursor;r_tidy();- cursor = limit - v_9;+ cursor = limit - v_8;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.javaindex 601e1c67a78..fd3e3b8a539 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/FrenchStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from french.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,18 +7,21 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from french.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {- new Among("col", -1, -1), new Among("par", -1, -1), new Among("tap", -1, -1)+ private static final Among[] a_0 = {+ new Among("col", -1, -1),+ new Among("ni", -1, 1),+ new Among("par", -1, -1),+ new Among("tap", -1, -1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 7),new Among("H", 0, 6),new Among("He", 1, 4),@@ -28,7 +31,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("Y", 0, 3)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("iqU", -1, 3),new Among("abl", -1, 3),new Among("I\u00E8r", -1, 4),@@ -37,11 +40,11 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("iv", -1, 1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("ic", -1, 2), new Among("abil", -1, 1), new Among("iv", -1, 3)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("iqUe", -1, 1),new Among("atrice", -1, 2),new Among("ance", -1, 1),@@ -49,7 +52,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("logie", -1, 3),new Among("able", -1, 1),new Among("isme", -1, 1),- new Among("euse", -1, 11),+ new Among("euse", -1, 12),new Among("iste", -1, 1),new Among("ive", -1, 8),new Among("if", -1, 8),@@ -64,7 +67,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("logies", -1, 3),new Among("ables", -1, 1),new Among("ismes", -1, 1),- new Among("euses", -1, 11),+ new Among("euses", -1, 12),new Among("istes", -1, 1),new Among("ives", -1, 8),new Among("ifs", -1, 8),@@ -72,22 +75,23 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ations", -1, 2),new Among("utions", -1, 4),new Among("ateurs", -1, 2),- new Among("ments", -1, 15),+ new Among("ments", -1, 16),new Among("ements", 30, 6),- new Among("issements", 31, 12),+ new Among("issements", 31, 13),new Among("it\u00E9s", -1, 7),- new Among("ment", -1, 15),+ new Among("ment", -1, 16),new Among("ement", 34, 6),- new Among("issement", 35, 12),- new Among("amment", 34, 13),- new Among("emment", 34, 14),+ new Among("issement", 35, 13),+ new Among("amment", 34, 14),+ new Among("emment", 34, 15),new Among("aux", -1, 10),new Among("eaux", 39, 9),new Among("eux", -1, 1),+ new Among("oux", -1, 11),new Among("it\u00E9", -1, 7)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ira", -1, 1),new Among("ie", -1, 1),new Among("isse", -1, 1),@@ -125,48 +129,55 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("issez", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {+ new Among("al", -1, 1), new Among("\u00E9pl", -1, -1), new Among("auv", -1, -1)+ };++ private static final Among[] a_7 = {new Among("a", -1, 3),new Among("era", 0, 2),+ new Among("aise", -1, 4),new Among("asse", -1, 3),new Among("ante", -1, 3),new Among("\u00E9e", -1, 2),new Among("ai", -1, 3),- new Among("erai", 5, 2),+ new Among("erai", 6, 2),new Among("er", -1, 2),new Among("as", -1, 3),- new Among("eras", 8, 2),+ new Among("eras", 9, 2),new Among("\u00E2mes", -1, 3),+ new Among("aises", -1, 4),new Among("asses", -1, 3),new Among("antes", -1, 3),new Among("\u00E2tes", -1, 3),new Among("\u00E9es", -1, 2),- new Among("ais", -1, 3),- new Among("erais", 15, 2),+ new Among("ais", -1, 4),+ new Among("eais", 17, 2),+ new Among("erais", 17, 2),new Among("ions", -1, 1),- new Among("erions", 17, 2),- new Among("assions", 17, 3),+ new Among("erions", 20, 2),+ new Among("assions", 20, 3),new Among("erons", -1, 2),new Among("ants", -1, 3),new Among("\u00E9s", -1, 2),new Among("ait", -1, 3),- new Among("erait", 23, 2),+ new Among("erait", 26, 2),new Among("ant", -1, 3),new Among("aIent", -1, 3),- new Among("eraIent", 26, 2),+ new Among("eraIent", 29, 2),new Among("\u00E8rent", -1, 2),new Among("assent", -1, 3),new Among("eront", -1, 2),new Among("\u00E2t", -1, 3),new Among("ez", -1, 2),- new Among("iez", 32, 2),- new Among("eriez", 33, 2),- new Among("assiez", 33, 3),- new Among("erez", 32, 2),+ new Among("iez", 35, 2),+ new Among("eriez", 36, 2),+ new Among("assiez", 36, 3),+ new Among("erez", 35, 2),new Among("\u00E9", -1, 2)};- private static final Among a_7[] = {+ private static final Among[] a_8 = {new Among("e", -1, 3),new Among("I\u00E8re", 0, 2),new Among("i\u00E8re", 0, 2),@@ -175,7 +186,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ier", -1, 2)};- private static final Among a_8[] = {+ private static final Among[] a_9 = {new Among("ell", -1, -1),new Among("eill", -1, -1),new Among("enn", -1, -1),@@ -183,11 +194,15 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ett", -1, -1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 130, 103, 8, 5};- private static final char g_keep_with_s[] = {+ private static final char[] g_oux_ending = {65, 85};++ private static final char[] g_elision_char = {131, 14, 3};++ private static final char[] g_keep_with_s = {1, 65, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128};@@ -195,6 +210,38 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {private int I_p1;private int I_pV;+ private boolean r_elisions() {+ bra = cursor;+ lab0:+ {+ int v_1 = cursor;+ lab1:+ {+ if (!(in_grouping(g_elision_char, 99, 116))) {+ break lab1;+ }+ break lab0;+ }+ cursor = v_1;+ if (!(eq_s("qu"))) {+ return false;+ }+ }+ if (!(eq_s("'"))) {+ return false;+ }+ ket = cursor;+ lab2:+ {+ if (cursor < limit) {+ break lab2;+ }+ return false;+ }+ slice_del();+ return true;+ }+private boolean r_prelude() {while (true) {int v_1 = cursor;@@ -316,6 +363,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_mark_regions() {+ int among_var;I_pV = limit;I_p1 = limit;I_p2 = limit;@@ -342,9 +390,17 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = v_2;lab3:{- if (find_among(a_0) == 0) {+ among_var = find_among(a_0);+ if (among_var == 0) {break lab3;}+ switch (among_var) {+ case 1:+ if (!(in_grouping(g_v, 97, 251))) {+ break lab3;+ }+ break;+ }break lab1;}cursor = v_2;@@ -352,87 +408,37 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {break lab0;}cursor++;- golab4:- while (true) {- lab5:- {- if (!(in_grouping(g_v, 97, 251))) {- break lab5;- }- break golab4;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 251)) {+ break lab0;}+ cursor++;}I_pV = cursor;}cursor = v_1;- int v_4 = cursor;- lab6:+ int v_3 = cursor;+ lab4:{- golab7:- while (true) {- lab8:- {- if (!(in_grouping(g_v, 97, 251))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab6;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 251)) {+ break lab4;}- golab9:- while (true) {- lab10:- {- if (!(out_grouping(g_v, 97, 251))) {- break lab10;- }- break golab9;- }- if (cursor >= limit) {- break lab6;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 251)) {+ break lab4;}+ cursor++;I_p1 = cursor;- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 251))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab6;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 251)) {+ break lab4;}- golab13:- while (true) {- lab14:- {- if (!(out_grouping(g_v, 97, 251))) {- break lab14;- }- break golab13;- }- if (cursor >= limit) {- break lab6;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 251)) {+ break lab4;}+ cursor++;I_p2 = cursor;}- cursor = v_4;+ cursor = v_3;return true;}@@ -734,6 +740,12 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("al");break;case 11:+ if (!(in_grouping_b(g_oux_ending, 98, 112))) {+ return false;+ }+ slice_from("ou");+ break;+ case 12:lab14:{int v_10 = limit - cursor;@@ -752,7 +764,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("eux");}break;- case 12:+ case 13:if (!r_R1()) {return false;}@@ -761,19 +773,19 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();break;- case 13:+ case 14:if (!r_RV()) {return false;}slice_from("ant");return false;- case 14:+ case 15:if (!r_RV()) {return false;}slice_from("ent");return false;- case 15:+ case 16:int v_11 = limit - cursor;if (!(in_grouping_b(g_v, 97, 251))) {return false;@@ -792,32 +804,32 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;if (find_among_b(a_5) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{if (!(eq_s_b("H"))) {break lab0;}- limit_backward = v_2;+ limit_backward = v_1;return false;}- cursor = limit - v_3;+ cursor = limit - v_2;}if (!(out_grouping_b(g_v, 97, 251))) {- limit_backward = v_2;+ limit_backward = v_1;return false;}slice_del();- limit_backward = v_2;+ limit_backward = v_1;return true;}@@ -826,19 +838,19 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;- among_var = find_among_b(a_6);+ among_var = find_among_b(a_7);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;+ limit_backward = v_1;switch (among_var) {case 1:if (!r_R2()) {- limit_backward = v_2;return false;}slice_del();@@ -847,21 +859,48 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {slice_del();break;case 3:- slice_del();- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{- ket = cursor;if (!(eq_s_b("e"))) {- cursor = limit - v_3;+ cursor = limit - v_2;+ break lab0;+ }+ if (!r_RV()) {+ cursor = limit - v_2;break lab0;}bra = cursor;- slice_del();}+ slice_del();+ break;+ case 4:+ {+ int v_3 = limit - cursor;+ lab1:+ {+ among_var = find_among_b(a_6);+ if (among_var == 0) {+ break lab1;+ }+ switch (among_var) {+ case 1:+ if (cursor <= limit_backward) {+ break lab1;+ }+ cursor--;+ if (cursor > limit_backward) {+ break lab1;+ }+ break;+ }+ return false;+ }+ cursor = limit - v_3;+ }+ slice_del();break;}- limit_backward = v_2;return true;}@@ -899,24 +938,24 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_5 = limit_backward;+ int v_4 = limit_backward;limit_backward = I_pV;ket = cursor;- among_var = find_among_b(a_7);+ among_var = find_among_b(a_8);if (among_var == 0) {- limit_backward = v_5;+ limit_backward = v_4;return false;}bra = cursor;switch (among_var) {case 1:if (!r_R2()) {- limit_backward = v_5;+ limit_backward = v_4;return false;}lab3:{- int v_6 = limit - cursor;+ int v_5 = limit - cursor;lab4:{if (!(eq_s_b("s"))) {@@ -924,9 +963,9 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_6;+ cursor = limit - v_5;if (!(eq_s_b("t"))) {- limit_backward = v_5;+ limit_backward = v_4;return false;}}@@ -939,13 +978,13 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {slice_del();break;}- limit_backward = v_5;+ limit_backward = v_4;return true;}private boolean r_un_double() {int v_1 = limit - cursor;- if (find_among_b(a_8) == 0) {+ if (find_among_b(a_9) == 0) {return false;}cursor = limit - v_1;@@ -980,7 +1019,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {ket = cursor;lab1:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab2:{if (!(eq_s_b("\u00E9"))) {@@ -988,7 +1027,7 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_3;+ cursor = limit - v_2;if (!(eq_s_b("\u00E8"))) {return false;}@@ -1001,8 +1040,11 @@ public class FrenchStemmer extends org.tartarus.snowball.SnowballStemmer {@Overridepublic boolean stem() {int v_1 = cursor;- r_prelude();+ r_elisions();cursor = v_1;+ int v_2 = cursor;+ r_prelude();+ cursor = v_2;r_mark_regions();limit_backward = cursor;cursor = limit;diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.javaindex b0481b634ee..abd9b70a006 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GermanStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from german.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from german.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 5),new Among("ae", 0, 2),new Among("oe", 0, 3),@@ -23,7 +23,7 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00DF", 0, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 5),new Among("U", 0, 2),new Among("Y", 0, 1),@@ -32,23 +32,39 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00FC", 0, 2)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("e", -1, 3),new Among("em", -1, 1),new Among("en", -1, 3),+ new Among("erinnen", 2, 2),+ new Among("erin", -1, 2),+ new Among("ln", -1, 5),new Among("ern", -1, 2),new Among("er", -1, 2),new Among("s", -1, 4),- new Among("es", 5, 3)+ new Among("es", 8, 3),+ new Among("lns", 8, 5)};- private static final Among a_3[] = {- new Among("en", -1, 1), new Among("er", -1, 1), new Among("st", -1, 2), new Among("est", 2, 1)+ private static final Among[] a_3 = {+ new Among("tick", -1, -1),+ new Among("plan", -1, -1),+ new Among("geordn", -1, -1),+ new Among("intern", -1, -1),+ new Among("tr", -1, -1)};- private static final Among a_4[] = {new Among("ig", -1, 1), new Among("lich", -1, 1)};+ private static final Among[] a_4 = {+ new Among("en", -1, 1),+ new Among("er", -1, 1),+ new Among("et", -1, 3),+ new Among("st", -1, 2),+ new Among("est", 3, 1)+ };++ private static final Among[] a_5 = {new Among("ig", -1, 1), new Among("lich", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_6 = {new Among("end", -1, 1),new Among("ig", -1, 2),new Among("ung", -1, 1),@@ -59,15 +75,18 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("keit", -1, 4)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 32, 8};- private static final char g_s_ending[] = {117, 30, 5};+ private static final char[] g_et_ending = {+ 1, 128, 198, 227, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128+ };++ private static final char[] g_s_ending = {117, 30, 5};- private static final char g_st_ending[] = {117, 30, 4};+ private static final char[] g_st_ending = {117, 30, 4};- private int I_x;private int I_p2;private int I_p1;@@ -163,6 +182,7 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_mark_regions() {+ int I_x;I_p1 = limit;I_p2 = limit;int v_1 = cursor;@@ -175,70 +195,30 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {}I_x = cursor;cursor = v_1;- golab0:- while (true) {- lab1:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab1;- }- break golab0;- }- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ return false;}+ cursor++;I_p1 = cursor;- lab4:+ lab0:{if (I_p1 >= I_x) {- break lab4;+ break lab0;}I_p1 = I_x;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ return false;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ return false;}+ cursor++;I_p2 = cursor;return true;}@@ -344,6 +324,9 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();break;+ case 5:+ slice_from("l");+ break;}}cursor = limit - v_1;@@ -351,7 +334,7 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {lab3:{ket = cursor;- among_var = find_among_b(a_3);+ among_var = find_among_b(a_4);if (among_var == 0) {break lab3;}@@ -376,117 +359,136 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();break;+ case 3:+ int v_5 = limit - cursor;+ if (!(in_grouping_b(g_et_ending, 85, 228))) {+ break lab3;+ }+ cursor = limit - v_5;+ {+ int v_6 = limit - cursor;+ lab4:+ {+ if (find_among_b(a_3) == 0) {+ break lab4;+ }+ break lab3;+ }+ cursor = limit - v_6;+ }+ slice_del();+ break;}}cursor = limit - v_4;- int v_5 = limit - cursor;- lab4:+ int v_7 = limit - cursor;+ lab5:{ket = cursor;- among_var = find_among_b(a_5);+ among_var = find_among_b(a_6);if (among_var == 0) {- break lab4;+ break lab5;}bra = cursor;if (!r_R2()) {- break lab4;+ break lab5;}switch (among_var) {case 1:slice_del();- int v_6 = limit - cursor;- lab5:+ int v_8 = limit - cursor;+ lab6:{ket = cursor;if (!(eq_s_b("ig"))) {- cursor = limit - v_6;- break lab5;+ cursor = limit - v_8;+ break lab6;}bra = cursor;{- int v_7 = limit - cursor;- lab6:+ int v_9 = limit - cursor;+ lab7:{if (!(eq_s_b("e"))) {- break lab6;+ break lab7;}- cursor = limit - v_6;- break lab5;+ cursor = limit - v_8;+ break lab6;}- cursor = limit - v_7;+ cursor = limit - v_9;}if (!r_R2()) {- cursor = limit - v_6;- break lab5;+ cursor = limit - v_8;+ break lab6;}slice_del();}break;case 2:{- int v_8 = limit - cursor;- lab7:+ int v_10 = limit - cursor;+ lab8:{if (!(eq_s_b("e"))) {- break lab7;+ break lab8;}- break lab4;+ break lab5;}- cursor = limit - v_8;+ cursor = limit - v_10;}slice_del();break;case 3:slice_del();- int v_9 = limit - cursor;- lab8:+ int v_11 = limit - cursor;+ lab9:{ket = cursor;- lab9:+ lab10:{- int v_10 = limit - cursor;- lab10:+ int v_12 = limit - cursor;+ lab11:{if (!(eq_s_b("er"))) {- break lab10;+ break lab11;}- break lab9;+ break lab10;}- cursor = limit - v_10;+ cursor = limit - v_12;if (!(eq_s_b("en"))) {- cursor = limit - v_9;- break lab8;+ cursor = limit - v_11;+ break lab9;}}bra = cursor;if (!r_R1()) {- cursor = limit - v_9;- break lab8;+ cursor = limit - v_11;+ break lab9;}slice_del();}break;case 4:slice_del();- int v_11 = limit - cursor;- lab11:+ int v_13 = limit - cursor;+ lab12:{ket = cursor;- if (find_among_b(a_4) == 0) {- cursor = limit - v_11;- break lab11;+ if (find_among_b(a_5) == 0) {+ cursor = limit - v_13;+ break lab12;}bra = cursor;if (!r_R2()) {- cursor = limit - v_11;- break lab11;+ cursor = limit - v_13;+ break lab12;}slice_del();}break;}}- cursor = limit - v_5;+ cursor = limit - v_7;return true;}@@ -502,9 +504,9 @@ public class GermanStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = limit;r_standard_suffix();cursor = limit_backward;- int v_4 = cursor;+ int v_3 = cursor;r_postlude();- cursor = v_4;+ cursor = v_3;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.javaindex 77c97f8657b..7ca43f73f65 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/GreekStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from greek.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from greek.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 25),new Among("\u0386", 0, 1),new Among("\u0388", 0, 5),@@ -63,7 +63,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03CE", 0, 24)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u03C3\u03BA\u03B1\u03B3\u03B9\u03B1", -1, 2),new Among("\u03C6\u03B1\u03B3\u03B9\u03B1", -1, 1),new Among("\u03BF\u03BB\u03BF\u03B3\u03B9\u03B1", -1, 3),@@ -106,7 +106,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C4\u03B1\u03C4\u03BF\u03B3\u03B9\u03BF\u03C5", -1, 5)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u03C0\u03B1", -1, 1),new Among("\u03BE\u03B1\u03BD\u03B1\u03C0\u03B1", 0, 1),new Among("\u03B5\u03C0\u03B1", 0, 1),@@ -140,7 +140,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BB\u03BF\u03C5", -1, 2)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u03B9\u03B6\u03B1", -1, 1),new Among("\u03B9\u03B6\u03B5", -1, 1),new Among("\u03B9\u03B6\u03B1\u03BC\u03B5", -1, 1),@@ -157,7 +157,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03B6\u03C9", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("\u03B2\u03B9", -1, 1),new Among("\u03BB\u03B9", -1, 1),new Among("\u03B1\u03BB", -1, 1),@@ -168,7 +168,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B6\u03C9", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("\u03C9\u03B8\u03B7\u03BA\u03B1", -1, 1),new Among("\u03C9\u03B8\u03B7\u03BA\u03B5", -1, 1),new Among("\u03C9\u03B8\u03B7\u03BA\u03B1\u03BC\u03B5", -1, 1),@@ -178,7 +178,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C9\u03B8\u03B7\u03BA\u03B5\u03C3", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("\u03BE\u03B1\u03BD\u03B1\u03C0\u03B1", -1, 1),new Among("\u03B5\u03C0\u03B1", -1, 1),new Among("\u03C0\u03B5\u03C1\u03B9\u03C0\u03B1", -1, 1),@@ -213,7 +213,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B3\u03B9\u03B3\u03B1\u03BD\u03C4\u03BF\u03B1\u03C6", 30, 2)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("\u03B9\u03C3\u03B1", -1, 1),new Among("\u03B9\u03C3\u03B1\u03BC\u03B5", -1, 1),new Among("\u03B9\u03C3\u03B1\u03BD\u03B5", -1, 1),@@ -223,7 +223,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03C3\u03B5\u03C3", -1, 1)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("\u03BE\u03B1\u03BD\u03B1\u03C0\u03B1", -1, 1),new Among("\u03B5\u03C0\u03B1", -1, 1),new Among("\u03C0\u03B5\u03C1\u03B9\u03C0\u03B1", -1, 1),@@ -245,7 +245,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03C5\u03BD\u03B1\u03B8\u03C1\u03BF", 17, 1)};- private static final Among a_9[] = {+ private static final Among[] a_9 = {new Among("\u03B9\u03C3\u03BF\u03C5\u03BC\u03B5", -1, 1),new Among("\u03B9\u03C3\u03BF\u03C5\u03BD\u03B5", -1, 1),new Among("\u03B9\u03C3\u03B5\u03C4\u03B5", -1, 1),@@ -255,7 +255,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03C3\u03C9", -1, 1)};- private static final Among a_10[] = {+ private static final Among[] a_10 = {new Among("\u03B1\u03C4\u03B1", -1, 2),new Among("\u03C6\u03B1", -1, 2),new Among("\u03B7\u03C6\u03B1", 1, 2),@@ -298,7 +298,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C5\u03C8", -1, 2)};- private static final Among a_11[] = {+ private static final Among[] a_11 = {new Among("\u03B9\u03C3\u03C4\u03B1", -1, 1),new Among("\u03B9\u03C3\u03C4\u03B5", -1, 1),new Among("\u03B9\u03C3\u03C4\u03B7", -1, 1),@@ -312,7 +312,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03C3\u03C4\u03BF\u03C5", -1, 1)};- private static final Among a_12[] = {+ private static final Among[] a_12 = {new Among("\u03B5\u03B3\u03BA\u03BB\u03B5", -1, 1),new Among("\u03B1\u03C0\u03BF\u03BA\u03BB\u03B5", -1, 1),new Among("\u03B4\u03B1\u03BD\u03B5", -1, 2),@@ -322,7 +322,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BC\u03B9\u03BA\u03C1\u03BF\u03C3\u03B5", 4, 1)};- private static final Among a_13[] = {+ private static final Among[] a_13 = {new Among("\u03B1\u03C4\u03BF\u03BC\u03B9\u03BA", -1, 2),new Among("\u03B5\u03B8\u03BD\u03B9\u03BA", -1, 4),new Among("\u03C4\u03BF\u03C0\u03B9\u03BA", -1, 7),@@ -335,7 +335,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B2\u03C5\u03B6\u03B1\u03BD\u03C4\u03B9\u03BD", -1, 9)};- private static final Among a_14[] = {+ private static final Among[] a_14 = {new Among("\u03B9\u03C3\u03BC\u03BF\u03B9", -1, 1),new Among("\u03B9\u03C3\u03BC\u03C9\u03BD", -1, 1),new Among("\u03B9\u03C3\u03BC\u03BF", -1, 1),@@ -344,16 +344,16 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03C3\u03BC\u03BF\u03C5", -1, 1)};- private static final Among a_15[] = {new Among("\u03C3", -1, 1), new Among("\u03C7", -1, 1)};+ private static final Among[] a_15 = {new Among("\u03C3", -1, 1), new Among("\u03C7", -1, 1)};- private static final Among a_16[] = {+ private static final Among[] a_16 = {new Among("\u03BF\u03C5\u03B4\u03B1\u03BA\u03B9\u03B1", -1, 1),new Among("\u03B1\u03C1\u03B1\u03BA\u03B9\u03B1", -1, 1),new Among("\u03BF\u03C5\u03B4\u03B1\u03BA\u03B9", -1, 1),new Among("\u03B1\u03C1\u03B1\u03BA\u03B9", -1, 1)};- private static final Among a_17[] = {+ private static final Among[] a_17 = {new Among("\u03B2", -1, 2),new Among("\u03B2\u03B1\u03BC\u03B2", 0, 1),new Among("\u03C3\u03BB\u03BF\u03B2", 0, 1),@@ -402,7 +402,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C7", -1, 1)};- private static final Among a_18[] = {+ private static final Among[] a_18 = {new Among("\u03B1\u03BA\u03B9\u03B1", -1, 1),new Among("\u03B1\u03C1\u03B1\u03BA\u03B9\u03B1", 0, 1),new Among("\u03B9\u03C4\u03C3\u03B1", -1, 1),@@ -413,24 +413,24 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03C4\u03C3\u03B5\u03C3", -1, 1)};- private static final Among a_19[] = {+ private static final Among[] a_19 = {new Among("\u03C8\u03B1\u03BB", -1, 1),new Among("\u03B1\u03B9\u03C6\u03BD", -1, 1),new Among("\u03BF\u03BB\u03BF", -1, 1),new Among("\u03B9\u03C1", -1, 1)};- private static final Among a_20[] = {+ private static final Among[] a_20 = {new Among("\u03B5", -1, 1), new Among("\u03C0\u03B1\u03B9\u03C7\u03BD", -1, 1)};- private static final Among a_21[] = {+ private static final Among[] a_21 = {new Among("\u03B9\u03B4\u03B9\u03B1", -1, 1),new Among("\u03B9\u03B4\u03B9\u03C9\u03BD", -1, 1),new Among("\u03B9\u03B4\u03B9\u03BF", -1, 1)};- private static final Among a_22[] = {+ private static final Among[] a_22 = {new Among("\u03B9\u03B2", -1, 1),new Among("\u03B4", -1, 1),new Among("\u03C6\u03C1\u03B1\u03B3\u03BA", -1, 1),@@ -440,18 +440,18 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C1", -1, 1)};- private static final Among a_23[] = {+ private static final Among[] a_23 = {new Among("\u03B9\u03C3\u03BA\u03B5", -1, 1),new Among("\u03B9\u03C3\u03BA\u03BF", -1, 1),new Among("\u03B9\u03C3\u03BA\u03BF\u03C3", -1, 1),new Among("\u03B9\u03C3\u03BA\u03BF\u03C5", -1, 1)};- private static final Among a_24[] = {+ private static final Among[] a_24 = {new Among("\u03B1\u03B4\u03C9\u03BD", -1, 1), new Among("\u03B1\u03B4\u03B5\u03C3", -1, 1)};- private static final Among a_25[] = {+ private static final Among[] a_25 = {new Among("\u03B3\u03B9\u03B1\u03B3\u03B9", -1, -1),new Among("\u03B8\u03B5\u03B9", -1, -1),new Among("\u03BF\u03BA", -1, -1),@@ -464,11 +464,11 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BD\u03C4\u03B1\u03BD\u03C4", -1, -1)};- private static final Among a_26[] = {+ private static final Among[] a_26 = {new Among("\u03B5\u03B4\u03C9\u03BD", -1, 1), new Among("\u03B5\u03B4\u03B5\u03C3", -1, 1)};- private static final Among a_27[] = {+ private static final Among[] a_27 = {new Among("\u03BC\u03B9\u03BB", -1, 1),new Among("\u03B4\u03B1\u03C0", -1, 1),new Among("\u03B3\u03B7\u03C0", -1, 1),@@ -479,12 +479,12 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C5\u03C0", -1, 1)};- private static final Among a_28[] = {+ private static final Among[] a_28 = {new Among("\u03BF\u03C5\u03B4\u03C9\u03BD", -1, 1),new Among("\u03BF\u03C5\u03B4\u03B5\u03C3", -1, 1)};- private static final Among a_29[] = {+ private static final Among[] a_29 = {new Among("\u03C4\u03C1\u03B1\u03B3", -1, 1),new Among("\u03C6\u03B5", -1, 1),new Among("\u03BA\u03B1\u03BB\u03B9\u03B1\u03BA", -1, 1),@@ -502,11 +502,11 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BB\u03B9\u03C7", -1, 1)};- private static final Among a_30[] = {+ private static final Among[] a_30 = {new Among("\u03B5\u03C9\u03BD", -1, 1), new Among("\u03B5\u03C9\u03C3", -1, 1)};- private static final Among a_31[] = {+ private static final Among[] a_31 = {new Among("\u03B4", -1, 1),new Among("\u03B9\u03B4", 0, 1),new Among("\u03B8", -1, 1),@@ -517,20 +517,20 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C0\u03B1\u03C1", -1, 1)};- private static final Among a_32[] = {+ private static final Among[] a_32 = {new Among("\u03B9\u03B1", -1, 1),new Among("\u03B9\u03C9\u03BD", -1, 1),new Among("\u03B9\u03BF\u03C5", -1, 1)};- private static final Among a_33[] = {+ private static final Among[] a_33 = {new Among("\u03B9\u03BA\u03B1", -1, 1),new Among("\u03B9\u03BA\u03C9\u03BD", -1, 1),new Among("\u03B9\u03BA\u03BF", -1, 1),new Among("\u03B9\u03BA\u03BF\u03C5", -1, 1)};- private static final Among a_34[] = {+ private static final Among[] a_34 = {new Among("\u03B1\u03B4", -1, 1),new Among("\u03C3\u03C5\u03BD\u03B1\u03B4", 0, 1),new Among("\u03BA\u03B1\u03C4\u03B1\u03B4", 0, 1),@@ -569,7 +569,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03B5\u03C1\u03C4", -1, 1)};- private static final Among a_35[] = {+ private static final Among[] a_35 = {new Among("\u03B1\u03B3\u03B1\u03BC\u03B5", -1, 1),new Among("\u03B7\u03BA\u03B1\u03BC\u03B5", -1, 1),new Among("\u03B7\u03B8\u03B7\u03BA\u03B1\u03BC\u03B5", 1, 1),@@ -577,7 +577,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BF\u03C5\u03C3\u03B1\u03BC\u03B5", -1, 1)};- private static final Among a_36[] = {+ private static final Among[] a_36 = {new Among("\u03B2\u03BF\u03C5\u03B2", -1, 1),new Among("\u03BE\u03B5\u03B8", -1, 1),new Among("\u03C0\u03B5\u03B8", -1, 1),@@ -592,11 +592,11 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03B9\u03C7", 10, 1)};- private static final Among a_37[] = {+ private static final Among[] a_37 = {new Among("\u03C4\u03C1", -1, 1), new Among("\u03C4\u03C3", -1, 1)};- private static final Among a_38[] = {+ private static final Among[] a_38 = {new Among("\u03B1\u03B3\u03B1\u03BD\u03B5", -1, 1),new Among("\u03B7\u03BA\u03B1\u03BD\u03B5", -1, 1),new Among("\u03B7\u03B8\u03B7\u03BA\u03B1\u03BD\u03B5", 1, 1),@@ -610,7 +610,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B9\u03BF\u03C4\u03B1\u03BD\u03B5", 9, 1)};- private static final Among a_39[] = {+ private static final Among[] a_39 = {new Among("\u03C4\u03B1\u03B2", -1, 1),new Among("\u03BD\u03C4\u03B1\u03B2", 0, 1),new Among("\u03C8\u03B7\u03BB\u03BF\u03C4\u03B1\u03B2", 0, 1),@@ -708,9 +708,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BB\u03B9\u03C7", 87, 1)};- private static final Among a_40[] = {new Among("\u03B7\u03C3\u03B5\u03C4\u03B5", -1, 1)};-- private static final Among a_41[] = {+ private static final Among[] a_40 = {new Among("\u03B5\u03BD\u03B4", -1, 1),new Among("\u03C3\u03C5\u03BD\u03B4", -1, 1),new Among("\u03BF\u03B4", -1, 1),@@ -744,7 +742,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03C7", -1, 1)};- private static final Among a_42[] = {+ private static final Among[] a_41 = {new Among("\u03C0\u03B1\u03B3", -1, 1),new Among("\u03B4", -1, 1),new Among("\u03B1\u03B4", 1, 1),@@ -772,17 +770,17 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03C5\u03C1\u03C6", -1, 1)};- private static final Among a_43[] = {+ private static final Among[] a_42 = {new Among("\u03BF\u03BD\u03C4\u03B1\u03C3", -1, 1),new Among("\u03C9\u03BD\u03C4\u03B1\u03C3", -1, 1)};- private static final Among a_44[] = {+ private static final Among[] a_43 = {new Among("\u03BF\u03BC\u03B1\u03C3\u03C4\u03B5", -1, 1),new Among("\u03B9\u03BF\u03BC\u03B1\u03C3\u03C4\u03B5", 0, 1)};- private static final Among a_45[] = {+ private static final Among[] a_44 = {new Among("\u03C0", -1, 1),new Among("\u03B1\u03C0", 0, 1),new Among("\u03B1\u03BA\u03B1\u03C4\u03B1\u03C0", 1, 1),@@ -791,7 +789,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B1\u03BC\u03B5\u03C4\u03B1\u03BC\u03C6", -1, 1)};- private static final Among a_46[] = {+ private static final Among[] a_45 = {new Among("\u03B6", -1, 1),new Among("\u03B1\u03BB", -1, 1),new Among("\u03C0\u03B1\u03C1\u03B1\u03BA\u03B1\u03BB", 1, 1),@@ -803,13 +801,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BD\u03B9\u03C3", -1, 1)};- private static final Among a_47[] = {+ private static final Among[] a_46 = {new Among("\u03B7\u03B8\u03B7\u03BA\u03B1", -1, 1),new Among("\u03B7\u03B8\u03B7\u03BA\u03B5", -1, 1),new Among("\u03B7\u03B8\u03B7\u03BA\u03B5\u03C3", -1, 1)};- private static final Among a_48[] = {+ private static final Among[] a_47 = {new Among("\u03C0\u03B9\u03B8", -1, 1),new Among("\u03BF\u03B8", -1, 1),new Among("\u03BD\u03B1\u03C1\u03B8", -1, 1),@@ -818,7 +816,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C3\u03C6", -1, 1)};- private static final Among a_49[] = {+ private static final Among[] a_48 = {new Among("\u03B8", -1, 1),new Among("\u03B4\u03B9\u03B1\u03B8", 0, 1),new Among("\u03C0\u03B1\u03C1\u03B1\u03BA\u03B1\u03C4\u03B1\u03B8", 0, 1),@@ -826,13 +824,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C0\u03C1\u03BF\u03C3\u03B8", 0, 1)};- private static final Among a_50[] = {+ private static final Among[] a_49 = {new Among("\u03B7\u03BA\u03B1", -1, 1),new Among("\u03B7\u03BA\u03B5", -1, 1),new Among("\u03B7\u03BA\u03B5\u03C3", -1, 1)};- private static final Among a_51[] = {+ private static final Among[] a_50 = {new Among("\u03C6\u03B1\u03B3", -1, 1),new Among("\u03BB\u03B7\u03B3", -1, 1),new Among("\u03C6\u03C1\u03C5\u03B4", -1, 1),@@ -847,7 +845,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C0\u03B1\u03BD\u03C4\u03B1\u03C7", -1, 1)};- private static final Among a_52[] = {+ private static final Among[] a_51 = {new Among("\u03C4\u03C3\u03B1", -1, 1),new Among("\u03C7\u03B1\u03B4", -1, 1),new Among("\u03BC\u03B5\u03B4", -1, 1),@@ -875,13 +873,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BB\u03B5\u03C7", -1, 1)};- private static final Among a_53[] = {+ private static final Among[] a_52 = {new Among("\u03BF\u03C5\u03C3\u03B1", -1, 1),new Among("\u03BF\u03C5\u03C3\u03B5", -1, 1),new Among("\u03BF\u03C5\u03C3\u03B5\u03C3", -1, 1)};- private static final Among a_54[] = {+ private static final Among[] a_53 = {new Among("\u03C0\u03B5\u03BB", -1, 1),new Among("\u03BB\u03BB", -1, 1),new Among("\u03C3\u03BC\u03B7\u03BD", -1, 1),@@ -896,7 +894,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BD\u03B1\u03C5\u03BB\u03BF\u03C7", 10, -1)};- private static final Among a_55[] = {+ private static final Among[] a_54 = {new Among("\u03B1\u03BC\u03B1\u03BB\u03BB\u03B9", -1, 1),new Among("\u03BB", -1, 1),new Among("\u03B1\u03BC\u03B1\u03BB", 1, 1),@@ -943,19 +941,19 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C0\u03BF\u03BB\u03C5\u03C6", -1, 1)};- private static final Among a_56[] = {+ private static final Among[] a_55 = {new Among("\u03B1\u03B3\u03B1", -1, 1),new Among("\u03B1\u03B3\u03B5", -1, 1),new Among("\u03B1\u03B3\u03B5\u03C3", -1, 1)};- private static final Among a_57[] = {+ private static final Among[] a_56 = {new Among("\u03B7\u03C3\u03B1", -1, 1),new Among("\u03B7\u03C3\u03B5", -1, 1),new Among("\u03B7\u03C3\u03BF\u03C5", -1, 1)};- private static final Among a_58[] = {+ private static final Among[] a_57 = {new Among("\u03BD", -1, 1),new Among("\u03B4\u03C9\u03B4\u03B5\u03BA\u03B1\u03BD", 0, 1),new Among("\u03B5\u03C0\u03C4\u03B1\u03BD", 0, 1),@@ -964,9 +962,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C7\u03B5\u03C1\u03C3\u03BF\u03BD", 0, 1)};- private static final Among a_59[] = {new Among("\u03B7\u03C3\u03C4\u03B5", -1, 1)};-- private static final Among a_60[] = {+ private static final Among[] a_58 = {new Among("\u03C3\u03B2", -1, 1),new Among("\u03B1\u03C3\u03B2", 0, 1),new Among("\u03B1\u03C0\u03BB", -1, 1),@@ -979,13 +975,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C0\u03B1\u03BB\u03B9\u03BC\u03C8", -1, 1)};- private static final Among a_61[] = {+ private static final Among[] a_59 = {new Among("\u03BF\u03C5\u03BD\u03B5", -1, 1),new Among("\u03B7\u03B8\u03BF\u03C5\u03BD\u03B5", 0, 1),new Among("\u03B7\u03C3\u03BF\u03C5\u03BD\u03B5", 0, 1)};- private static final Among a_62[] = {+ private static final Among[] a_60 = {new Among("\u03C3\u03C0\u03B9", -1, 1),new Among("\u03BD", -1, 1),new Among("\u03B5\u03BE\u03C9\u03BD", 1, 1),@@ -994,13 +990,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03BA\u03B1\u03BA\u03BF\u03BC\u03BF\u03C5\u03C4\u03C3", -1, 1)};- private static final Among a_63[] = {+ private static final Among[] a_61 = {new Among("\u03BF\u03C5\u03BC\u03B5", -1, 1),new Among("\u03B7\u03B8\u03BF\u03C5\u03BC\u03B5", 0, 1),new Among("\u03B7\u03C3\u03BF\u03C5\u03BC\u03B5", 0, 1)};- private static final Among a_64[] = {+ private static final Among[] a_62 = {new Among("\u03B1\u03B6", -1, 1),new Among("\u03C9\u03C1\u03B9\u03BF\u03C0\u03BB", -1, 1),new Among("\u03B1\u03C3\u03BF\u03C5\u03C3", -1, 1),@@ -1010,13 +1006,13 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C7", -1, 1)};- private static final Among a_65[] = {+ private static final Among[] a_63 = {new Among("\u03BC\u03B1\u03C4\u03B1", -1, 1),new Among("\u03BC\u03B1\u03C4\u03C9\u03BD", -1, 1),new Among("\u03BC\u03B1\u03C4\u03BF\u03C3", -1, 1)};- private static final Among a_66[] = {+ private static final Among[] a_64 = {new Among("\u03B1", -1, 1),new Among("\u03B9\u03BF\u03C5\u03BC\u03B1", 0, 1),new Among("\u03BF\u03BC\u03BF\u03C5\u03BD\u03B1", 0, 1),@@ -1103,7 +1099,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03B7\u03C3\u03C9", 80, 1)};- private static final Among a_67[] = {+ private static final Among[] a_65 = {new Among("\u03BF\u03C4\u03B5\u03C1", -1, 1),new Among("\u03B5\u03C3\u03C4\u03B5\u03C1", -1, 1),new Among("\u03C5\u03C4\u03B5\u03C1", -1, 1),@@ -1114,9 +1110,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u03C9\u03C4\u03B1\u03C4", -1, 1)};- private static final char g_v[] = {81, 65, 16, 1};+ private static final char[] g_v = {81, 65, 16, 1};- private static final char g_v2[] = {81, 65, 0, 1};+ private static final char[] g_v2 = {81, 65, 0, 1};private boolean B_test1;@@ -1221,7 +1217,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step1() {+ private boolean r_step_1() {int among_var;ket = cursor;among_var = find_among_b(a_1);@@ -1268,7 +1264,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps1() {+ private boolean r_step_s1() {int among_var;ket = cursor;if (find_among_b(a_3) == 0) {@@ -1297,7 +1293,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps2() {+ private boolean r_step_s2() {ket = cursor;if (find_among_b(a_5) == 0) {return false;@@ -1317,23 +1313,18 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps3() {+ private boolean r_step_s3() {int among_var;- ket = cursor;- if (find_among_b(a_7) == 0) {- return false;- }- bra = cursor;- slice_del();- B_test1 = false;lab0:{int v_1 = limit - cursor;lab1:{+ ket = cursor;if (!(eq_s_b("\u03B9\u03C3\u03B1"))) {break lab1;}+ bra = cursor;if (cursor > limit_backward) {break lab1;}@@ -1342,27 +1333,34 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor = limit - v_1;ket = cursor;- bra = cursor;- among_var = find_among_b(a_6);- if (among_var == 0) {- return false;- }- if (cursor > limit_backward) {- return false;- }- switch (among_var) {- case 1:- slice_from("\u03B9");- break;- case 2:- slice_from("\u03B9\u03C3");- break;- }+ }+ if (find_among_b(a_7) == 0) {+ return false;+ }+ bra = cursor;+ slice_del();+ B_test1 = false;+ ket = cursor;+ bra = cursor;+ among_var = find_among_b(a_6);+ if (among_var == 0) {+ return false;+ }+ if (cursor > limit_backward) {+ return false;+ }+ switch (among_var) {+ case 1:+ slice_from("\u03B9");+ break;+ case 2:+ slice_from("\u03B9\u03C3");+ break;}return true;}- private boolean r_steps4() {+ private boolean r_step_s4() {ket = cursor;if (find_among_b(a_9) == 0) {return false;@@ -1382,7 +1380,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps5() {+ private boolean r_step_s5() {int among_var;ket = cursor;if (find_among_b(a_11) == 0) {@@ -1411,7 +1409,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps6() {+ private boolean r_step_s6() {int among_var;ket = cursor;if (find_among_b(a_14) == 0) {@@ -1487,7 +1485,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps7() {+ private boolean r_step_s7() {ket = cursor;if (find_among_b(a_16) == 0) {return false;@@ -1507,7 +1505,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps8() {+ private boolean r_step_s8() {int among_var;ket = cursor;if (find_among_b(a_18) == 0) {@@ -1551,7 +1549,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps9() {+ private boolean r_step_s9() {ket = cursor;if (find_among_b(a_21) == 0) {return false;@@ -1586,7 +1584,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_steps10() {+ private boolean r_step_s10() {ket = cursor;if (find_among_b(a_23) == 0) {return false;@@ -1606,7 +1604,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step2a() {+ private boolean r_step_2a() {ket = cursor;if (find_among_b(a_24) == 0) {return false;@@ -1632,7 +1630,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step2b() {+ private boolean r_step_2b() {ket = cursor;if (find_among_b(a_26) == 0) {return false;@@ -1648,7 +1646,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step2c() {+ private boolean r_step_2c() {ket = cursor;if (find_among_b(a_28) == 0) {return false;@@ -1664,7 +1662,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step2d() {+ private boolean r_step_2d() {ket = cursor;if (find_among_b(a_30) == 0) {return false;@@ -1684,7 +1682,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step3() {+ private boolean r_step_3() {ket = cursor;if (find_among_b(a_32) == 0) {return false;@@ -1701,7 +1699,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step4() {+ private boolean r_step_4() {ket = cursor;if (find_among_b(a_33) == 0) {return false;@@ -1736,13 +1734,15 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5a() {+ private boolean r_step_5a() {int v_1 = limit - cursor;lab0:{+ ket = cursor;if (!(eq_s_b("\u03B1\u03B3\u03B1\u03BC\u03B5"))) {break lab0;}+ bra = cursor;if (cursor > limit_backward) {break lab0;}@@ -1780,7 +1780,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5b() {+ private boolean r_step_5b() {int v_1 = limit - cursor;lab0:{@@ -1836,12 +1836,12 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5c() {+ private boolean r_step_5c() {int v_1 = limit - cursor;lab0:{ket = cursor;- if (find_among_b(a_40) == 0) {+ if (!(eq_s_b("\u03B7\u03C3\u03B5\u03C4\u03B5"))) {break lab0;}bra = cursor;@@ -1874,7 +1874,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {{ket = cursor;bra = cursor;- if (find_among_b(a_41) == 0) {+ if (find_among_b(a_40) == 0) {break lab3;}slice_from("\u03B5\u03C4");@@ -1884,7 +1884,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {ket = cursor;}bra = cursor;- if (find_among_b(a_42) == 0) {+ if (find_among_b(a_41) == 0) {return false;}if (cursor > limit_backward) {@@ -1894,9 +1894,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5d() {+ private boolean r_step_5d() {ket = cursor;- if (find_among_b(a_43) == 0) {+ if (find_among_b(a_42) == 0) {return false;}bra = cursor;@@ -1929,9 +1929,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5e() {+ private boolean r_step_5e() {ket = cursor;- if (find_among_b(a_44) == 0) {+ if (find_among_b(a_43) == 0) {return false;}bra = cursor;@@ -1949,7 +1949,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5f() {+ private boolean r_step_5f() {int v_1 = limit - cursor;lab0:{@@ -1962,7 +1962,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_45) == 0) {+ if (find_among_b(a_44) == 0) {break lab0;}if (cursor > limit_backward) {@@ -1980,7 +1980,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_46) == 0) {+ if (find_among_b(a_45) == 0) {return false;}if (cursor > limit_backward) {@@ -1990,12 +1990,12 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5g() {+ private boolean r_step_5g() {int v_1 = limit - cursor;lab0:{ket = cursor;- if (find_among_b(a_47) == 0) {+ if (find_among_b(a_46) == 0) {break lab0;}bra = cursor;@@ -2004,7 +2004,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor = limit - v_1;ket = cursor;- if (find_among_b(a_50) == 0) {+ if (find_among_b(a_49) == 0) {return false;}bra = cursor;@@ -2017,7 +2017,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {{ket = cursor;bra = cursor;- if (find_among_b(a_48) == 0) {+ if (find_among_b(a_47) == 0) {break lab2;}slice_from("\u03B7\u03BA");@@ -2026,7 +2026,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = limit - v_2;ket = cursor;bra = cursor;- if (find_among_b(a_49) == 0) {+ if (find_among_b(a_48) == 0) {return false;}if (cursor > limit_backward) {@@ -2037,9 +2037,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5h() {+ private boolean r_step_5h() {ket = cursor;- if (find_among_b(a_53) == 0) {+ if (find_among_b(a_52) == 0) {return false;}bra = cursor;@@ -2052,7 +2052,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {{ket = cursor;bra = cursor;- if (find_among_b(a_51) == 0) {+ if (find_among_b(a_50) == 0) {break lab1;}slice_from("\u03BF\u03C5\u03C3");@@ -2061,7 +2061,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = limit - v_1;ket = cursor;bra = cursor;- if (find_among_b(a_52) == 0) {+ if (find_among_b(a_51) == 0) {return false;}if (cursor > limit_backward) {@@ -2072,10 +2072,10 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5i() {+ private boolean r_step_5i() {int among_var;ket = cursor;- if (find_among_b(a_56) == 0) {+ if (find_among_b(a_55) == 0) {return false;}bra = cursor;@@ -2102,7 +2102,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {{ket = cursor;bra = cursor;- among_var = find_among_b(a_54);+ among_var = find_among_b(a_53);if (among_var == 0) {break lab3;}@@ -2116,7 +2116,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = limit - v_2;ket = cursor;bra = cursor;- if (find_among_b(a_55) == 0) {+ if (find_among_b(a_54) == 0) {return false;}if (cursor > limit_backward) {@@ -2128,9 +2128,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5j() {+ private boolean r_step_5j() {ket = cursor;- if (find_among_b(a_57) == 0) {+ if (find_among_b(a_56) == 0) {return false;}bra = cursor;@@ -2138,7 +2138,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_58) == 0) {+ if (find_among_b(a_57) == 0) {return false;}if (cursor > limit_backward) {@@ -2148,9 +2148,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5k() {+ private boolean r_step_5k() {ket = cursor;- if (find_among_b(a_59) == 0) {+ if (!(eq_s_b("\u03B7\u03C3\u03C4\u03B5"))) {return false;}bra = cursor;@@ -2158,7 +2158,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_60) == 0) {+ if (find_among_b(a_58) == 0) {return false;}if (cursor > limit_backward) {@@ -2168,9 +2168,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5l() {+ private boolean r_step_5l() {ket = cursor;- if (find_among_b(a_61) == 0) {+ if (find_among_b(a_59) == 0) {return false;}bra = cursor;@@ -2178,7 +2178,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_62) == 0) {+ if (find_among_b(a_60) == 0) {return false;}if (cursor > limit_backward) {@@ -2188,9 +2188,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step5m() {+ private boolean r_step_5m() {ket = cursor;- if (find_among_b(a_63) == 0) {+ if (find_among_b(a_61) == 0) {return false;}bra = cursor;@@ -2198,7 +2198,7 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {B_test1 = false;ket = cursor;bra = cursor;- if (find_among_b(a_64) == 0) {+ if (find_among_b(a_62) == 0) {return false;}if (cursor > limit_backward) {@@ -2208,23 +2208,23 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step6() {+ private boolean r_step_6() {int v_1 = limit - cursor;lab0:{ket = cursor;- if (find_among_b(a_65) == 0) {+ if (find_among_b(a_63) == 0) {break lab0;}bra = cursor;slice_from("\u03BC\u03B1");}cursor = limit - v_1;- if (!(B_test1)) {+ if (!B_test1) {return false;}ket = cursor;- if (find_among_b(a_66) == 0) {+ if (find_among_b(a_64) == 0) {return false;}bra = cursor;@@ -2232,9 +2232,9 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_step7() {+ private boolean r_step_7() {ket = cursor;- if (find_among_b(a_67) == 0) {+ if (find_among_b(a_65) == 0) {return false;}bra = cursor;@@ -2254,100 +2254,100 @@ public class GreekStemmer extends org.tartarus.snowball.SnowballStemmer {}B_test1 = true;int v_2 = limit - cursor;- r_step1();+ r_step_1();cursor = limit - v_2;int v_3 = limit - cursor;- r_steps1();+ r_step_s1();cursor = limit - v_3;int v_4 = limit - cursor;- r_steps2();+ r_step_s2();cursor = limit - v_4;int v_5 = limit - cursor;- r_steps3();+ r_step_s3();cursor = limit - v_5;int v_6 = limit - cursor;- r_steps4();+ r_step_s4();cursor = limit - v_6;int v_7 = limit - cursor;- r_steps5();+ r_step_s5();cursor = limit - v_7;int v_8 = limit - cursor;- r_steps6();+ r_step_s6();cursor = limit - v_8;int v_9 = limit - cursor;- r_steps7();+ r_step_s7();cursor = limit - v_9;int v_10 = limit - cursor;- r_steps8();+ r_step_s8();cursor = limit - v_10;int v_11 = limit - cursor;- r_steps9();+ r_step_s9();cursor = limit - v_11;int v_12 = limit - cursor;- r_steps10();+ r_step_s10();cursor = limit - v_12;int v_13 = limit - cursor;- r_step2a();+ r_step_2a();cursor = limit - v_13;int v_14 = limit - cursor;- r_step2b();+ r_step_2b();cursor = limit - v_14;int v_15 = limit - cursor;- r_step2c();+ r_step_2c();cursor = limit - v_15;int v_16 = limit - cursor;- r_step2d();+ r_step_2d();cursor = limit - v_16;int v_17 = limit - cursor;- r_step3();+ r_step_3();cursor = limit - v_17;int v_18 = limit - cursor;- r_step4();+ r_step_4();cursor = limit - v_18;int v_19 = limit - cursor;- r_step5a();+ r_step_5a();cursor = limit - v_19;int v_20 = limit - cursor;- r_step5b();+ r_step_5b();cursor = limit - v_20;int v_21 = limit - cursor;- r_step5c();+ r_step_5c();cursor = limit - v_21;int v_22 = limit - cursor;- r_step5d();+ r_step_5d();cursor = limit - v_22;int v_23 = limit - cursor;- r_step5e();+ r_step_5e();cursor = limit - v_23;int v_24 = limit - cursor;- r_step5f();+ r_step_5f();cursor = limit - v_24;int v_25 = limit - cursor;- r_step5g();+ r_step_5g();cursor = limit - v_25;int v_26 = limit - cursor;- r_step5h();+ r_step_5h();cursor = limit - v_26;int v_27 = limit - cursor;- r_step5j();+ r_step_5j();cursor = limit - v_27;int v_28 = limit - cursor;- r_step5i();+ r_step_5i();cursor = limit - v_28;int v_29 = limit - cursor;- r_step5k();+ r_step_5k();cursor = limit - v_29;int v_30 = limit - cursor;- r_step5l();+ r_step_5l();cursor = limit - v_30;int v_31 = limit - cursor;- r_step5m();+ r_step_5m();cursor = limit - v_31;int v_32 = limit - cursor;- r_step6();+ r_step_6();cursor = limit - v_32;int v_33 = limit - cursor;- r_step7();+ r_step_7();cursor = limit - v_33;cursor = limit_backward;return true;diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.javaindex 56203c4c3c7..62396a64a3b 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HindiStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from hindi.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,7 +7,7 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from hindi.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class HindiStemmer extends org.tartarus.snowball.SnowballStemmer {@@ -16,7 +16,7 @@ public class HindiStemmer extends org.tartarus.snowball.SnowballStemmer {private static final java.lang.invoke.MethodHandles.Lookup methodObject =java.lang.invoke.MethodHandles.lookup();- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0906\u0901", -1, -1),new Among("\u093E\u0901", -1, -1),new Among("\u0907\u092F\u093E\u0901", 1, -1),@@ -151,13 +151,10 @@ public class HindiStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u094D", -1, -1)};- private static final char g_consonant[] = {255, 255, 255, 255, 159, 0, 0, 0, 248, 7};+ private static final char[] g_consonant = {255, 255, 255, 255, 159, 0, 0, 0, 248, 7};- public boolean r_CONSONANT() {- if (!(in_grouping_b(g_consonant, 2325, 2399))) {- return false;- }- return true;+ private boolean r_CONSONANT() {+ return in_grouping_b(g_consonant, 2325, 2399);}@Overridediff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.javaindex 624aea0d349..eebb8e9acc0 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/HungarianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from hungarian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,27 +7,16 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from hungarian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {- new Among("cs", -1, -1),- new Among("dzs", -1, -1),- new Among("gy", -1, -1),- new Among("ly", -1, -1),- new Among("ny", -1, -1),- new Among("sz", -1, -1),- new Among("ty", -1, -1),- new Among("zs", -1, -1)- };-- private static final Among a_1[] = {new Among("\u00E1", -1, 1), new Among("\u00E9", -1, 2)};+ private static final Among[] a_0 = {new Among("\u00E1", -1, 1), new Among("\u00E9", -1, 2)};- private static final Among a_2[] = {+ private static final Among[] a_1 = {new Among("bb", -1, -1),new Among("cc", -1, -1),new Among("dd", -1, -1),@@ -53,9 +42,9 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("zz", -1, -1)};- private static final Among a_3[] = {new Among("al", -1, 1), new Among("el", -1, 1)};+ private static final Among[] a_2 = {new Among("al", -1, 1), new Among("el", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_3 = {new Among("ba", -1, -1),new Among("ra", -1, -1),new Among("be", -1, -1),@@ -102,11 +91,11 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("v\u00E9", -1, -1)};- private static final Among a_5[] = {+ private static final Among[] a_4 = {new Among("\u00E1n", -1, 2), new Among("\u00E9n", -1, 1), new Among("\u00E1nk\u00E9nt", -1, 2)};- private static final Among a_6[] = {+ private static final Among[] a_5 = {new Among("stul", -1, 1),new Among("astul", 0, 1),new Among("\u00E1stul", 0, 2),@@ -115,9 +104,9 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00E9st\u00FCl", 3, 3)};- private static final Among a_7[] = {new Among("\u00E1", -1, 1), new Among("\u00E9", -1, 1)};+ private static final Among[] a_6 = {new Among("\u00E1", -1, 1), new Among("\u00E9", -1, 1)};- private static final Among a_8[] = {+ private static final Among[] a_7 = {new Among("k", -1, 3),new Among("ak", 0, 3),new Among("ek", 0, 3),@@ -127,7 +116,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F6k", 0, 3)};- private static final Among a_9[] = {+ private static final Among[] a_8 = {new Among("\u00E9i", -1, 1),new Among("\u00E1\u00E9i", 0, 3),new Among("\u00E9\u00E9i", 0, 2),@@ -142,7 +131,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00E9\u00E9", 3, 2)};- private static final Among a_10[] = {+ private static final Among[] a_9 = {new Among("a", -1, 1),new Among("ja", 0, 1),new Among("d", -1, 1),@@ -176,7 +165,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00E9", -1, 3)};- private static final Among a_11[] = {+ private static final Among[] a_10 = {new Among("id", -1, 1),new Among("aid", 0, 1),new Among("jaid", 1, 1),@@ -221,7 +210,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00E9im", 35, 3)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 17, 36, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,1, 0, 0, 0, 1};@@ -238,60 +227,23 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping(g_v, 97, 369))) {break lab1;}- golab2:- while (true) {- int v_2 = cursor;- lab3:- {- if (!(out_grouping(g_v, 97, 369))) {- break lab3;- }- cursor = v_2;- break golab2;- }- cursor = v_2;- if (cursor >= limit) {- break lab1;- }- cursor++;- }- lab4:+ int v_2 = cursor;+ lab2:{- int v_3 = cursor;- lab5:- {- if (find_among(a_0) == 0) {- break lab5;- }- break lab4;- }- cursor = v_3;- if (cursor >= limit) {- break lab1;+ if (!go_in_grouping(g_v, 97, 369)) {+ break lab2;}cursor++;+ I_p1 = cursor;}- I_p1 = cursor;+ cursor = v_2;break lab0;}cursor = v_1;- if (!(out_grouping(g_v, 97, 369))) {+ if (!go_out_grouping(g_v, 97, 369)) {return false;}- golab6:- while (true) {- lab7:- {- if (!(in_grouping(g_v, 97, 369))) {- break lab7;- }- break golab6;- }- if (cursor >= limit) {- return false;- }- cursor++;- }+ cursor++;I_p1 = cursor;}return true;@@ -304,7 +256,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_v_ending() {int among_var;ket = cursor;- among_var = find_among_b(a_1);+ among_var = find_among_b(a_0);if (among_var == 0) {return false;}@@ -325,7 +277,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_double() {int v_1 = limit - cursor;- if (find_among_b(a_2) == 0) {+ if (find_among_b(a_1) == 0) {return false;}cursor = limit - v_1;@@ -338,13 +290,10 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {}cursor--;ket = cursor;- {- int c = cursor - 1;- if (c < limit_backward) {- return false;- }- cursor = c;+ if (cursor <= limit_backward) {+ return false;}+ cursor--;bra = cursor;slice_del();return true;@@ -352,7 +301,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_instrum() {ket = cursor;- if (find_among_b(a_3) == 0) {+ if (find_among_b(a_2) == 0) {return false;}bra = cursor;@@ -363,15 +312,12 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}slice_del();- if (!r_undouble()) {- return false;- }- return true;+ return r_undouble();}private boolean r_case() {ket = cursor;- if (find_among_b(a_4) == 0) {+ if (find_among_b(a_3) == 0) {return false;}bra = cursor;@@ -379,16 +325,13 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}slice_del();- if (!r_v_ending()) {- return false;- }- return true;+ return r_v_ending();}private boolean r_case_special() {int among_var;ket = cursor;- among_var = find_among_b(a_5);+ among_var = find_among_b(a_4);if (among_var == 0) {return false;}@@ -410,7 +353,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_case_other() {int among_var;ket = cursor;- among_var = find_among_b(a_6);+ among_var = find_among_b(a_5);if (among_var == 0) {return false;}@@ -434,7 +377,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_factive() {ket = cursor;- if (find_among_b(a_7) == 0) {+ if (find_among_b(a_6) == 0) {return false;}bra = cursor;@@ -445,16 +388,13 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}slice_del();- if (!r_undouble()) {- return false;- }- return true;+ return r_undouble();}private boolean r_plural() {int among_var;ket = cursor;- among_var = find_among_b(a_8);+ among_var = find_among_b(a_7);if (among_var == 0) {return false;}@@ -479,7 +419,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_owned() {int among_var;ket = cursor;- among_var = find_among_b(a_9);+ among_var = find_among_b(a_8);if (among_var == 0) {return false;}@@ -504,7 +444,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_sing_owner() {int among_var;ket = cursor;- among_var = find_among_b(a_10);+ among_var = find_among_b(a_9);if (among_var == 0) {return false;}@@ -529,7 +469,7 @@ public class HungarianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_plur_owner() {int among_var;ket = cursor;- among_var = find_among_b(a_11);+ among_var = find_among_b(a_10);if (among_var == 0) {return false;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.javaindex 5e64001f2f5..e99410d9ace 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IndonesianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from indonesian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,54 +7,39 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from indonesian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final java.lang.invoke.MethodHandles.Lookup methodObject =- java.lang.invoke.MethodHandles.lookup();- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("kah", -1, 1), new Among("lah", -1, 1), new Among("pun", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("nya", -1, 1), new Among("ku", -1, 1), new Among("mu", -1, 1)};- private static final Among a_2[] = {- new Among("i", -1, 1, "r_SUFFIX_I_OK", methodObject),- new Among("an", -1, 1, "r_SUFFIX_AN_OK", methodObject),- new Among("kan", 1, 1, "r_SUFFIX_KAN_OK", methodObject)- };+ private static final Among[] a_2 = {new Among("i", -1, 2), new Among("an", -1, 1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("di", -1, 1),- new Among("ke", -1, 2),+ new Among("ke", -1, 3),new Among("me", -1, 1),new Among("mem", 2, 5),- new Among("men", 2, 1),+ new Among("men", 2, 2),new Among("meng", 4, 1),- new Among("meny", 4, 3, "r_VOWEL", methodObject),new Among("pem", -1, 6),- new Among("pen", -1, 2),- new Among("peng", 8, 2),- new Among("peny", 8, 4, "r_VOWEL", methodObject),+ new Among("pen", -1, 4),+ new Among("peng", 7, 3),new Among("ter", -1, 1)};- private static final Among a_4[] = {- new Among("be", -1, 3, "r_KER", methodObject),- new Among("belajar", 0, 4),- new Among("ber", 0, 3),- new Among("pe", -1, 1),- new Among("pelajar", 3, 2),- new Among("per", 3, 1)- };+ private static final Among[] a_4 = {new Among("be", -1, 2), new Among("pe", -1, 1)};- private static final char g_vowel[] = {17, 65, 16};+ private static final char[] g_vowel = {17, 65, 16};private int I_prefix;private int I_measure;@@ -81,66 +66,61 @@ public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- public boolean r_SUFFIX_KAN_OK() {- if (I_prefix == 3) {- return false;- }- if (I_prefix == 2) {- return false;- }- return true;- }-- public boolean r_SUFFIX_AN_OK() {- return I_prefix != 1;- }-- public boolean r_SUFFIX_I_OK() {- if (I_prefix > 2) {- return false;- }- {- int v_1 = limit - cursor;- lab0:- {- if (!(eq_s_b("s"))) {- break lab0;- }- return false;- }- cursor = limit - v_1;- }- return true;- }-private boolean r_remove_suffix() {+ int among_var;ket = cursor;- if (find_among_b(a_2) == 0) {+ among_var = find_among_b(a_2);+ if (among_var == 0) {return false;}bra = cursor;+ switch (among_var) {+ case 1:+ lab0:+ {+ int v_1 = limit - cursor;+ lab1:+ {+ if (I_prefix == 3) {+ break lab1;+ }+ if (I_prefix == 2) {+ break lab1;+ }+ if (!(eq_s_b("k"))) {+ break lab1;+ }+ bra = cursor;+ break lab0;+ }+ cursor = limit - v_1;+ if (I_prefix == 1) {+ return false;+ }+ }+ break;+ case 2:+ if (I_prefix > 2) {+ return false;+ }+ {+ int v_2 = limit - cursor;+ lab2:+ {+ if (!(eq_s_b("s"))) {+ break lab2;+ }+ return false;+ }+ cursor = limit - v_2;+ }+ break;+ }slice_del();I_measure -= 1;return true;}- public boolean r_VOWEL() {- if (!(in_grouping(g_vowel, 97, 117))) {- return false;- }- return true;- }-- public boolean r_KER() {- if (!(out_grouping(g_vowel, 97, 117))) {- return false;- }- if (!(eq_s("er"))) {- return false;- }- return true;- }-private boolean r_remove_first_order_prefix() {int among_var;bra = cursor;@@ -156,58 +136,100 @@ public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {I_measure -= 1;break;case 2:- slice_del();- I_prefix = 3;- I_measure -= 1;- break;- case 3:- I_prefix = 1;- slice_from("s");- I_measure -= 1;- break;- case 4:- I_prefix = 3;- slice_from("s");- I_measure -= 1;- break;- case 5:- I_prefix = 1;- I_measure -= 1;lab0:{int v_1 = cursor;lab1:{+ if (!(eq_s("y"))) {+ break lab1;+ }int v_2 = cursor;if (!(in_grouping(g_vowel, 97, 117))) {break lab1;}cursor = v_2;- slice_from("p");+ ket = cursor;+ slice_from("s");+ I_prefix = 1;+ I_measure -= 1;break lab0;}cursor = v_1;slice_del();+ I_prefix = 1;+ I_measure -= 1;}break;- case 6:+ case 3:+ slice_del();I_prefix = 3;I_measure -= 1;+ break;+ case 4:lab2:{int v_3 = cursor;lab3:{+ if (!(eq_s("y"))) {+ break lab3;+ }int v_4 = cursor;if (!(in_grouping(g_vowel, 97, 117))) {break lab3;}cursor = v_4;- slice_from("p");+ ket = cursor;+ slice_from("s");+ I_prefix = 3;+ I_measure -= 1;break lab2;}cursor = v_3;slice_del();+ I_prefix = 3;+ I_measure -= 1;+ }+ break;+ case 5:+ I_prefix = 1;+ I_measure -= 1;+ lab4:+ {+ int v_5 = cursor;+ lab5:+ {+ int v_6 = cursor;+ if (!(in_grouping(g_vowel, 97, 117))) {+ break lab5;+ }+ cursor = v_6;+ slice_from("p");+ break lab4;+ }+ cursor = v_5;+ slice_del();+ }+ break;+ case 6:+ I_prefix = 3;+ I_measure -= 1;+ lab6:+ {+ int v_7 = cursor;+ lab7:+ {+ int v_8 = cursor;+ if (!(in_grouping(g_vowel, 97, 117))) {+ break lab7;+ }+ cursor = v_8;+ slice_from("p");+ break lab6;+ }+ cursor = v_7;+ slice_del();}break;}@@ -221,28 +243,75 @@ public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {if (among_var == 0) {return false;}- ket = cursor;switch (among_var) {case 1:- slice_del();- I_prefix = 2;- I_measure -= 1;+ lab0:+ {+ int v_1 = cursor;+ lab1:+ {+ if (!(eq_s("r"))) {+ break lab1;+ }+ ket = cursor;+ I_prefix = 2;+ break lab0;+ }+ cursor = v_1;+ lab2:+ {+ if (!(eq_s("l"))) {+ break lab2;+ }+ ket = cursor;+ if (!(eq_s("ajar"))) {+ break lab2;+ }+ break lab0;+ }+ cursor = v_1;+ ket = cursor;+ I_prefix = 2;+ }break;case 2:- slice_from("ajar");- I_measure -= 1;- break;- case 3:- slice_del();- I_prefix = 4;- I_measure -= 1;- break;- case 4:- slice_from("ajar");+ lab3:+ {+ int v_2 = cursor;+ lab4:+ {+ if (!(eq_s("r"))) {+ break lab4;+ }+ ket = cursor;+ break lab3;+ }+ cursor = v_2;+ lab5:+ {+ if (!(eq_s("l"))) {+ break lab5;+ }+ ket = cursor;+ if (!(eq_s("ajar"))) {+ break lab5;+ }+ break lab3;+ }+ cursor = v_2;+ ket = cursor;+ if (!(out_grouping(g_vowel, 97, 117))) {+ return false;+ }+ if (!(eq_s("er"))) {+ return false;+ }+ }I_prefix = 4;- I_measure -= 1;break;}+ I_measure -= 1;+ slice_del();return true;}@@ -256,20 +325,10 @@ public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {int v_2 = cursor;lab1:{- golab2:- while (true) {- lab3:- {- if (!(in_grouping(g_vowel, 97, 117))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- break lab1;- }- cursor++;+ if (!go_out_grouping(g_vowel, 97, 117)) {+ break lab1;}+ cursor++;I_measure += 1;continue;}@@ -284,71 +343,71 @@ public class IndonesianStemmer extends org.tartarus.snowball.SnowballStemmer {I_prefix = 0;limit_backward = cursor;cursor = limit;- int v_4 = limit - cursor;+ int v_3 = limit - cursor;r_remove_particle();- cursor = limit - v_4;+ cursor = limit - v_3;if (I_measure <= 2) {return false;}- int v_5 = limit - cursor;+ int v_4 = limit - cursor;r_remove_possessive_pronoun();- cursor = limit - v_5;+ cursor = limit - v_4;cursor = limit_backward;if (I_measure <= 2) {return false;}- lab4:+ lab2:{- int v_6 = cursor;- lab5:+ int v_5 = cursor;+ lab3:{- int v_7 = cursor;+ int v_6 = cursor;if (!r_remove_first_order_prefix()) {- break lab5;+ break lab3;}- int v_8 = cursor;- lab6:+ int v_7 = cursor;+ lab4:{- int v_9 = cursor;+ int v_8 = cursor;if (I_measure <= 2) {- break lab6;+ break lab4;}limit_backward = cursor;cursor = limit;if (!r_remove_suffix()) {- break lab6;+ break lab4;}cursor = limit_backward;- cursor = v_9;+ cursor = v_8;if (I_measure <= 2) {- break lab6;+ break lab4;}if (!r_remove_second_order_prefix()) {- break lab6;+ break lab4;}}- cursor = v_8;cursor = v_7;- break lab4;+ cursor = v_6;+ break lab2;}- cursor = v_6;- int v_10 = cursor;+ cursor = v_5;+ int v_9 = cursor;r_remove_second_order_prefix();- cursor = v_10;- int v_11 = cursor;- lab7:+ cursor = v_9;+ int v_10 = cursor;+ lab5:{if (I_measure <= 2) {- break lab7;+ break lab5;}limit_backward = cursor;cursor = limit;if (!r_remove_suffix()) {- break lab7;+ break lab5;}cursor = limit_backward;}- cursor = v_11;+ cursor = v_10;}return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.javaindex 8b38eb5701a..f356283034e 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/IrishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from irish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from irish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("b'", -1, 1),new Among("bh", -1, 4),new Among("bhf", 1, 2),@@ -41,7 +41,7 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ts", -1, 3)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u00EDochta", -1, 1),new Among("a\u00EDochta", 0, 1),new Among("ire", -1, 2),@@ -60,7 +60,7 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("air\u00ED", 14, 2)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u00F3ideacha", -1, 6),new Among("patacha", -1, 5),new Among("achta", -1, 1),@@ -88,7 +88,7 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("grafa\u00EDochta\u00ED", -1, 4)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("imid", -1, 1),new Among("aimid", 0, 1),new Among("\u00EDmid", -1, 1),@@ -103,7 +103,7 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("tar", -1, 2)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 17, 4, 2};@@ -118,64 +118,24 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = cursor;lab0:{- golab1:- while (true) {- lab2:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab2;- }- break golab1;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab0;}+ cursor++;I_pV = cursor;- golab3:- while (true) {- lab4:- {- if (!(out_grouping(g_v, 97, 250))) {- break lab4;- }- break golab3;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 250)) {+ break lab0;}+ cursor++;I_p1 = cursor;- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab0;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 250))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 250)) {+ break lab0;}+ cursor++;I_p2 = cursor;}cursor = v_1;@@ -329,15 +289,15 @@ public class IrishStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_3 = limit - cursor;+ int v_2 = limit - cursor;r_noun_sfx();+ cursor = limit - v_2;+ int v_3 = limit - cursor;+ r_deriv();cursor = limit - v_3;int v_4 = limit - cursor;- r_deriv();- cursor = limit - v_4;- int v_5 = limit - cursor;r_verb_sfx();- cursor = limit - v_5;+ cursor = limit - v_4;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.javaindex 1335f783302..580bfb1084f 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/ItalianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from italian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from italian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 7),new Among("qu", 0, 6),new Among("\u00E1", 0, 1),@@ -24,11 +24,11 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00FA", 0, 5)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 3), new Among("I", 0, 1), new Among("U", 0, 2)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("la", -1, -1),new Among("cela", 0, -1),new Among("gliela", 0, -1),@@ -68,7 +68,7 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("velo", 31, -1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("ando", -1, 1),new Among("endo", -1, 1),new Among("ar", -1, 2),@@ -76,18 +76,18 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ir", -1, 2)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("ic", -1, -1),new Among("abil", -1, -1),new Among("os", -1, -1),new Among("iv", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ic", -1, 1), new Among("abil", -1, 1), new Among("iv", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("ica", -1, 1),new Among("logia", -1, 3),new Among("osa", -1, 1),@@ -141,7 +141,7 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ist\u00EC", -1, 1)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("isca", -1, 1),new Among("enda", -1, 1),new Among("ata", -1, 1),@@ -231,15 +231,15 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ir\u00F2", -1, 1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 128, 8, 2, 1};- private static final char g_AEIO[] = {+ private static final char[] g_AEIO = {17, 65, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 128, 8, 2};- private static final char g_CG[] = {17};+ private static final char[] g_CG = {17};private int I_p2;private int I_p1;@@ -365,40 +365,28 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 249))) {break lab4;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 249))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab4;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 249)) {+ break lab4;}+ cursor++;break lab3;}cursor = v_3;if (!(in_grouping(g_v, 97, 249))) {break lab2;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 249))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab2;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 249)) {+ break lab2;}+ cursor++;+ }+ break lab1;+ }+ cursor = v_2;+ lab5:+ {+ if (!(eq_s("divan"))) {+ break lab5;}break lab1;}@@ -406,31 +394,21 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 249))) {break lab0;}- lab9:+ lab6:{- int v_6 = cursor;- lab10:+ int v_4 = cursor;+ lab7:{if (!(out_grouping(g_v, 97, 249))) {- break lab10;+ break lab7;}- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 249))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab10;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 249)) {+ break lab7;}- break lab9;+ cursor++;+ break lab6;}- cursor = v_6;+ cursor = v_4;if (!(in_grouping(g_v, 97, 249))) {break lab0;}@@ -443,69 +421,29 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {I_pV = cursor;}cursor = v_1;- int v_8 = cursor;- lab13:+ int v_5 = cursor;+ lab8:{- golab14:- while (true) {- lab15:- {- if (!(in_grouping(g_v, 97, 249))) {- break lab15;- }- break golab14;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 249)) {+ break lab8;}- golab16:- while (true) {- lab17:- {- if (!(out_grouping(g_v, 97, 249))) {- break lab17;- }- break golab16;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 249)) {+ break lab8;}+ cursor++;I_p1 = cursor;- golab18:- while (true) {- lab19:- {- if (!(in_grouping(g_v, 97, 249))) {- break lab19;- }- break golab18;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 249)) {+ break lab8;}- golab20:- while (true) {- lab21:- {- if (!(out_grouping(g_v, 97, 249))) {- break lab21;- }- break golab20;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 249)) {+ break lab8;}+ cursor++;I_p2 = cursor;}- cursor = v_8;+ cursor = v_5;return true;}@@ -735,16 +673,16 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;if (find_among_b(a_7) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;slice_del();- limit_backward = v_2;+ limit_backward = v_1;return true;}@@ -797,69 +735,44 @@ public class ItalianStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_exceptions() {- bra = cursor;- if (!(eq_s("divano"))) {- return false;- }- if (cursor < limit) {- return false;- }- ket = cursor;- slice_from("divan");- return true;- }-@Overridepublic boolean stem() {+ int v_1 = cursor;+ r_prelude();+ cursor = v_1;+ r_mark_regions();+ limit_backward = cursor;+ cursor = limit;+ int v_2 = limit - cursor;+ r_attached_pronoun();+ cursor = limit - v_2;+ int v_3 = limit - cursor;lab0:{- int v_1 = cursor;lab1:{- if (!r_exceptions()) {- break lab1;- }- break lab0;- }- cursor = v_1;- int v_2 = cursor;- r_prelude();- cursor = v_2;- r_mark_regions();- limit_backward = cursor;- cursor = limit;- int v_4 = limit - cursor;- r_attached_pronoun();- cursor = limit - v_4;- int v_5 = limit - cursor;- lab2:- {- lab3:+ int v_4 = limit - cursor;+ lab2:{- int v_6 = limit - cursor;- lab4:- {- if (!r_standard_suffix()) {- break lab4;- }- break lab3;- }- cursor = limit - v_6;- if (!r_verb_suffix()) {+ if (!r_standard_suffix()) {break lab2;}+ break lab1;+ }+ cursor = limit - v_4;+ if (!r_verb_suffix()) {+ break lab0;}}- cursor = limit - v_5;- int v_7 = limit - cursor;- r_vowel_suffix();- cursor = limit - v_7;- cursor = limit_backward;- int v_8 = cursor;- r_postlude();- cursor = v_8;}+ cursor = limit - v_3;+ int v_5 = limit - cursor;+ r_vowel_suffix();+ cursor = limit - v_5;+ cursor = limit_backward;+ int v_6 = cursor;+ r_postlude();+ cursor = v_6;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.javaindex cf6d440a76a..97ebcb11d5e 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/LithuanianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from lithuanian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,221 +7,210 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from lithuanian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("a", -1, -1),new Among("ia", 0, -1),- new Among("eria", 1, -1),new Among("osna", 0, -1),- new Among("iosna", 3, -1),- new Among("uosna", 3, -1),- new Among("iuosna", 5, -1),+ new Among("iosna", 2, -1),+ new Among("uosna", 2, -1),+ new Among("iuosna", 4, -1),new Among("ysna", 0, -1),new Among("\u0117sna", 0, -1),new Among("e", -1, -1),- new Among("ie", 9, -1),- new Among("enie", 10, -1),- new Among("erie", 10, -1),- new Among("oje", 9, -1),- new Among("ioje", 13, -1),- new Among("uje", 9, -1),- new Among("iuje", 15, -1),- new Among("yje", 9, -1),- new Among("enyje", 17, -1),- new Among("eryje", 17, -1),- new Among("\u0117je", 9, -1),- new Among("ame", 9, -1),- new Among("iame", 21, -1),- new Among("sime", 9, -1),- new Among("ome", 9, -1),- new Among("\u0117me", 9, -1),- new Among("tum\u0117me", 25, -1),- new Among("ose", 9, -1),- new Among("iose", 27, -1),- new Among("uose", 27, -1),- new Among("iuose", 29, -1),- new Among("yse", 9, -1),- new Among("enyse", 31, -1),- new Among("eryse", 31, -1),- new Among("\u0117se", 9, -1),- new Among("ate", 9, -1),- new Among("iate", 35, -1),- new Among("ite", 9, -1),- new Among("kite", 37, -1),- new Among("site", 37, -1),- new Among("ote", 9, -1),- new Among("tute", 9, -1),- new Among("\u0117te", 9, -1),- new Among("tum\u0117te", 42, -1),+ new Among("ie", 8, -1),+ new Among("enie", 9, -1),+ new Among("oje", 8, -1),+ new Among("ioje", 11, -1),+ new Among("uje", 8, -1),+ new Among("iuje", 13, -1),+ new Among("yje", 8, -1),+ new Among("enyje", 15, -1),+ new Among("\u0117je", 8, -1),+ new Among("ame", 8, -1),+ new Among("iame", 18, -1),+ new Among("sime", 8, -1),+ new Among("ome", 8, -1),+ new Among("\u0117me", 8, -1),+ new Among("tum\u0117me", 22, -1),+ new Among("ose", 8, -1),+ new Among("iose", 24, -1),+ new Among("uose", 24, -1),+ new Among("iuose", 26, -1),+ new Among("yse", 8, -1),+ new Among("enyse", 28, -1),+ new Among("\u0117se", 8, -1),+ new Among("ate", 8, -1),+ new Among("iate", 31, -1),+ new Among("ite", 8, -1),+ new Among("kite", 33, -1),+ new Among("site", 33, -1),+ new Among("ote", 8, -1),+ new Among("tute", 8, -1),+ new Among("\u0117te", 8, -1),+ new Among("tum\u0117te", 38, -1),new Among("i", -1, -1),- new Among("ai", 44, -1),- new Among("iai", 45, -1),- new Among("eriai", 46, -1),- new Among("ei", 44, -1),- new Among("tumei", 48, -1),- new Among("ki", 44, -1),- new Among("imi", 44, -1),- new Among("erimi", 51, -1),- new Among("umi", 44, -1),- new Among("iumi", 53, -1),- new Among("si", 44, -1),- new Among("asi", 55, -1),- new Among("iasi", 56, -1),- new Among("esi", 55, -1),- new Among("iesi", 58, -1),- new Among("siesi", 59, -1),- new Among("isi", 55, -1),- new Among("aisi", 61, -1),- new Among("eisi", 61, -1),- new Among("tumeisi", 63, -1),- new Among("uisi", 61, -1),- new Among("osi", 55, -1),- new Among("\u0117josi", 66, -1),- new Among("uosi", 66, -1),- new Among("iuosi", 68, -1),- new Among("siuosi", 69, -1),- new Among("usi", 55, -1),- new Among("ausi", 71, -1),- new Among("\u010Diausi", 72, -1),- new Among("\u0105si", 55, -1),- new Among("\u0117si", 55, -1),- new Among("\u0173si", 55, -1),- new Among("t\u0173si", 76, -1),- new Among("ti", 44, -1),- new Among("enti", 78, -1),- new Among("inti", 78, -1),- new Among("oti", 78, -1),- new Among("ioti", 81, -1),- new Among("uoti", 81, -1),- new Among("iuoti", 83, -1),- new Among("auti", 78, -1),- new Among("iauti", 85, -1),- new Among("yti", 78, -1),- new Among("\u0117ti", 78, -1),- new Among("tel\u0117ti", 88, -1),- new Among("in\u0117ti", 88, -1),- new Among("ter\u0117ti", 88, -1),- new Among("ui", 44, -1),- new Among("iui", 92, -1),- new Among("eniui", 93, -1),+ new Among("ai", 40, -1),+ new Among("iai", 41, -1),+ new Among("ei", 40, -1),+ new Among("tumei", 43, -1),+ new Among("ki", 40, -1),+ new Among("imi", 40, -1),+ new Among("umi", 40, -1),+ new Among("iumi", 47, -1),+ new Among("si", 40, -1),+ new Among("asi", 49, -1),+ new Among("iasi", 50, -1),+ new Among("esi", 49, -1),+ new Among("iesi", 52, -1),+ new Among("siesi", 53, -1),+ new Among("isi", 49, -1),+ new Among("aisi", 55, -1),+ new Among("eisi", 55, -1),+ new Among("tumeisi", 57, -1),+ new Among("uisi", 55, -1),+ new Among("osi", 49, -1),+ new Among("\u0117josi", 60, -1),+ new Among("uosi", 60, -1),+ new Among("iuosi", 62, -1),+ new Among("siuosi", 63, -1),+ new Among("usi", 49, -1),+ new Among("ausi", 65, -1),+ new Among("\u010Diausi", 66, -1),+ new Among("\u0105si", 49, -1),+ new Among("\u0117si", 49, -1),+ new Among("\u0173si", 49, -1),+ new Among("t\u0173si", 70, -1),+ new Among("ti", 40, -1),+ new Among("enti", 72, -1),+ new Among("inti", 72, -1),+ new Among("oti", 72, -1),+ new Among("ioti", 75, -1),+ new Among("uoti", 75, -1),+ new Among("iuoti", 77, -1),+ new Among("auti", 72, -1),+ new Among("iauti", 79, -1),+ new Among("yti", 72, -1),+ new Among("\u0117ti", 72, -1),+ new Among("tel\u0117ti", 82, -1),+ new Among("in\u0117ti", 82, -1),+ new Among("ter\u0117ti", 82, -1),+ new Among("ui", 40, -1),+ new Among("iui", 86, -1),+ new Among("eniui", 87, -1),new Among("oj", -1, -1),new Among("\u0117j", -1, -1),new Among("k", -1, -1),new Among("am", -1, -1),- new Among("iam", 98, -1),+ new Among("iam", 92, -1),new Among("iem", -1, -1),new Among("im", -1, -1),- new Among("sim", 101, -1),+ new Among("sim", 95, -1),new Among("om", -1, -1),new Among("tum", -1, -1),new Among("\u0117m", -1, -1),- new Among("tum\u0117m", 105, -1),+ new Among("tum\u0117m", 99, -1),new Among("an", -1, -1),new Among("on", -1, -1),- new Among("ion", 108, -1),+ new Among("ion", 102, -1),new Among("un", -1, -1),- new Among("iun", 110, -1),+ new Among("iun", 104, -1),new Among("\u0117n", -1, -1),new Among("o", -1, -1),- new Among("io", 113, -1),- new Among("enio", 114, -1),- new Among("\u0117jo", 113, -1),- new Among("uo", 113, -1),+ new Among("io", 107, -1),+ new Among("enio", 108, -1),+ new Among("\u0117jo", 107, -1),+ new Among("uo", 107, -1),new Among("s", -1, -1),- new Among("as", 118, -1),- new Among("ias", 119, -1),- new Among("es", 118, -1),- new Among("ies", 121, -1),- new Among("is", 118, -1),- new Among("ais", 123, -1),- new Among("iais", 124, -1),- new Among("tumeis", 123, -1),- new Among("imis", 123, -1),- new Among("enimis", 127, -1),- new Among("omis", 123, -1),- new Among("iomis", 129, -1),- new Among("umis", 123, -1),- new Among("\u0117mis", 123, -1),- new Among("enis", 123, -1),- new Among("asis", 123, -1),- new Among("ysis", 123, -1),- new Among("ams", 118, -1),- new Among("iams", 136, -1),- new Among("iems", 118, -1),- new Among("ims", 118, -1),- new Among("enims", 139, -1),- new Among("erims", 139, -1),- new Among("oms", 118, -1),- new Among("ioms", 142, -1),- new Among("ums", 118, -1),- new Among("\u0117ms", 118, -1),- new Among("ens", 118, -1),- new Among("os", 118, -1),- new Among("ios", 147, -1),- new Among("uos", 147, -1),- new Among("iuos", 149, -1),- new Among("ers", 118, -1),- new Among("us", 118, -1),- new Among("aus", 152, -1),- new Among("iaus", 153, -1),- new Among("ius", 152, -1),- new Among("ys", 118, -1),- new Among("enys", 156, -1),- new Among("erys", 156, -1),- new Among("\u0105s", 118, -1),- new Among("i\u0105s", 159, -1),- new Among("\u0117s", 118, -1),- new Among("am\u0117s", 161, -1),- new Among("iam\u0117s", 162, -1),- new Among("im\u0117s", 161, -1),- new Among("kim\u0117s", 164, -1),- new Among("sim\u0117s", 164, -1),- new Among("om\u0117s", 161, -1),- new Among("\u0117m\u0117s", 161, -1),- new Among("tum\u0117m\u0117s", 168, -1),- new Among("at\u0117s", 161, -1),- new Among("iat\u0117s", 170, -1),- new Among("sit\u0117s", 161, -1),- new Among("ot\u0117s", 161, -1),- new Among("\u0117t\u0117s", 161, -1),- new Among("tum\u0117t\u0117s", 174, -1),- new Among("\u012Fs", 118, -1),- new Among("\u016Bs", 118, -1),- new Among("t\u0173s", 118, -1),+ new Among("as", 112, -1),+ new Among("ias", 113, -1),+ new Among("es", 112, -1),+ new Among("ies", 115, -1),+ new Among("is", 112, -1),+ new Among("ais", 117, -1),+ new Among("iais", 118, -1),+ new Among("tumeis", 117, -1),+ new Among("imis", 117, -1),+ new Among("enimis", 121, -1),+ new Among("omis", 117, -1),+ new Among("iomis", 123, -1),+ new Among("umis", 117, -1),+ new Among("\u0117mis", 117, -1),+ new Among("enis", 117, -1),+ new Among("asis", 117, -1),+ new Among("ysis", 117, -1),+ new Among("ams", 112, -1),+ new Among("iams", 130, -1),+ new Among("iems", 112, -1),+ new Among("ims", 112, -1),+ new Among("enims", 133, -1),+ new Among("oms", 112, -1),+ new Among("ioms", 135, -1),+ new Among("ums", 112, -1),+ new Among("\u0117ms", 112, -1),+ new Among("ens", 112, -1),+ new Among("os", 112, -1),+ new Among("ios", 140, -1),+ new Among("uos", 140, -1),+ new Among("iuos", 142, -1),+ new Among("us", 112, -1),+ new Among("aus", 144, -1),+ new Among("iaus", 145, -1),+ new Among("ius", 144, -1),+ new Among("ys", 112, -1),+ new Among("enys", 148, -1),+ new Among("\u0105s", 112, -1),+ new Among("i\u0105s", 150, -1),+ new Among("\u0117s", 112, -1),+ new Among("am\u0117s", 152, -1),+ new Among("iam\u0117s", 153, -1),+ new Among("im\u0117s", 152, -1),+ new Among("kim\u0117s", 155, -1),+ new Among("sim\u0117s", 155, -1),+ new Among("om\u0117s", 152, -1),+ new Among("\u0117m\u0117s", 152, -1),+ new Among("tum\u0117m\u0117s", 159, -1),+ new Among("at\u0117s", 152, -1),+ new Among("iat\u0117s", 161, -1),+ new Among("sit\u0117s", 152, -1),+ new Among("ot\u0117s", 152, -1),+ new Among("\u0117t\u0117s", 152, -1),+ new Among("tum\u0117t\u0117s", 165, -1),+ new Among("\u012Fs", 112, -1),+ new Among("\u016Bs", 112, -1),+ new Among("t\u0173s", 112, -1),new Among("at", -1, -1),- new Among("iat", 179, -1),+ new Among("iat", 170, -1),new Among("it", -1, -1),- new Among("sit", 181, -1),+ new Among("sit", 172, -1),new Among("ot", -1, -1),new Among("\u0117t", -1, -1),- new Among("tum\u0117t", 184, -1),+ new Among("tum\u0117t", 175, -1),new Among("u", -1, -1),- new Among("au", 186, -1),- new Among("iau", 187, -1),- new Among("\u010Diau", 188, -1),- new Among("iu", 186, -1),- new Among("eniu", 190, -1),- new Among("siu", 190, -1),+ new Among("au", 177, -1),+ new Among("iau", 178, -1),+ new Among("\u010Diau", 179, -1),+ new Among("iu", 177, -1),+ new Among("eniu", 181, -1),+ new Among("siu", 181, -1),new Among("y", -1, -1),new Among("\u0105", -1, -1),- new Among("i\u0105", 194, -1),+ new Among("i\u0105", 185, -1),new Among("\u0117", -1, -1),new Among("\u0119", -1, -1),new Among("\u012F", -1, -1),- new Among("en\u012F", 198, -1),- new Among("er\u012F", 198, -1),+ new Among("en\u012F", 189, -1),new Among("\u0173", -1, -1),- new Among("i\u0173", 201, -1),- new Among("er\u0173", 201, -1)+ new Among("i\u0173", 191, -1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("ing", -1, -1),new Among("aj", -1, -1),new Among("iaj", 1, -1),@@ -286,7 +275,7 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0117j\u0119", 60, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ojime", -1, 7),new Among("\u0117jime", -1, 3),new Among("avime", -1, 6),@@ -300,11 +289,9 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("esiu", -1, 4)};- private static final Among a_3[] = {new Among("\u010D", -1, 1), new Among("d\u017E", -1, 2)};+ private static final Among[] a_3 = {new Among("\u010D", -1, 1), new Among("d\u017E", -1, 2)};- private static final Among a_4[] = {new Among("gd", -1, 1)};-- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 64, 1, 0, 64, 0, 0, 0, 0,0, 0, 0, 4, 4};@@ -315,15 +302,15 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;if (find_among_b(a_0) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;slice_del();return true;}@@ -336,15 +323,15 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {break lab0;}- int v_3 = limit_backward;+ int v_2 = limit_backward;limit_backward = I_p1;ket = cursor;if (find_among_b(a_1) == 0) {- limit_backward = v_3;+ limit_backward = v_2;break lab0;}bra = cursor;- limit_backward = v_3;+ limit_backward = v_2;slice_del();continue;}@@ -412,7 +399,7 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_fix_gd() {ket = cursor;- if (find_among_b(a_4) == 0) {+ if (!(eq_s_b("gd"))) {return false;}bra = cursor;@@ -429,76 +416,46 @@ public class LithuanianStemmer extends org.tartarus.snowball.SnowballStemmer {int v_2 = cursor;lab1:{- int v_3 = cursor;if (!(eq_s("a"))) {cursor = v_2;break lab1;}- cursor = v_3;if (length <= 6) {cursor = v_2;break lab1;}- {- int c = cursor + 1;- if (c > limit) {- cursor = v_2;- break lab1;- }- cursor = c;- }}- golab2:- while (true) {- lab3:- {- if (!(in_grouping(g_v, 97, 371))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 371)) {+ break lab0;}- golab4:- while (true) {- lab5:- {- if (!(out_grouping(g_v, 97, 371))) {- break lab5;- }- break golab4;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 371)) {+ break lab0;}+ cursor++;I_p1 = cursor;}cursor = v_1;limit_backward = cursor;cursor = limit;- int v_6 = limit - cursor;+ int v_3 = limit - cursor;r_fix_conflicts();- cursor = limit - v_6;- int v_7 = limit - cursor;+ cursor = limit - v_3;+ int v_4 = limit - cursor;r_step1();- cursor = limit - v_7;- int v_8 = limit - cursor;+ cursor = limit - v_4;+ int v_5 = limit - cursor;r_fix_chdz();- cursor = limit - v_8;- int v_9 = limit - cursor;+ cursor = limit - v_5;+ int v_6 = limit - cursor;r_step2();- cursor = limit - v_9;- int v_10 = limit - cursor;+ cursor = limit - v_6;+ int v_7 = limit - cursor;r_fix_chdz();- cursor = limit - v_10;- int v_11 = limit - cursor;+ cursor = limit - v_7;+ int v_8 = limit - cursor;r_fix_gd();- cursor = limit - v_11;+ cursor = limit - v_8;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.javaindex b850488ffd6..9b9be9d5ff4 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NepaliStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from nepali.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from nepali.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0932\u093E\u0907", -1, 1),new Among("\u0932\u093E\u0908", -1, 1),new Among("\u0938\u0901\u0917", -1, 1),@@ -34,15 +34,11 @@ public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0915\u094B", -1, 2)};- private static final Among a_1[] = {- new Among("\u0901", -1, -1), new Among("\u0902", -1, -1), new Among("\u0948", -1, -1)- };-- private static final Among a_2[] = {+ private static final Among[] a_1 = {new Among("\u0901", -1, 1), new Among("\u0902", -1, 1), new Among("\u0948", -1, 2)};- private static final Among a_3[] = {+ private static final Among[] a_2 = {new Among("\u0925\u093F\u090F", -1, 1),new Among("\u091B", -1, 1),new Among("\u0907\u091B", 1, 1),@@ -154,20 +150,16 @@ public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = limit - cursor;lab1:{- lab2:- {- int v_2 = limit - cursor;- lab3:- {- if (!(eq_s_b("\u090F"))) {- break lab3;- }- break lab2;- }- cursor = limit - v_2;- if (!(eq_s_b("\u0947"))) {- break lab1;- }+ if (!(eq_s_b("\u090F"))) {+ break lab1;+ }+ break lab0;+ }+ cursor = limit - v_1;+ lab2:+ {+ if (!(eq_s_b("\u0947"))) {+ break lab2;}break lab0;}@@ -179,19 +171,10 @@ public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_check_category_2() {- ket = cursor;- if (find_among_b(a_1) == 0) {- return false;- }- bra = cursor;- return true;- }-private boolean r_remove_category_2() {int among_var;ket = cursor;- among_var = find_among_b(a_2);+ among_var = find_among_b(a_1);if (among_var == 0) {return false;}@@ -243,7 +226,7 @@ public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {private boolean r_remove_category_3() {ket = cursor;- if (find_among_b(a_3) == 0) {+ if (find_among_b(a_2) == 0) {return false;}bra = cursor;@@ -258,36 +241,21 @@ public class NepaliStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = limit - cursor;r_remove_category_1();cursor = limit - v_1;- int v_2 = limit - cursor;- lab0:- {- while (true) {+ while (true) {+ int v_2 = limit - cursor;+ lab0:+ {int v_3 = limit - cursor;- lab1:- {- int v_4 = limit - cursor;- lab2:- {- int v_5 = limit - cursor;- if (!r_check_category_2()) {- break lab2;- }- cursor = limit - v_5;- if (!r_remove_category_2()) {- break lab2;- }- }- cursor = limit - v_4;- if (!r_remove_category_3()) {- break lab1;- }- continue;- }+ r_remove_category_2();cursor = limit - v_3;- break;+ if (!r_remove_category_3()) {+ break lab0;+ }+ continue;}+ cursor = limit - v_2;+ break;}- cursor = limit - v_2;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.javaindex 7ebccadbde0..3eee3130349 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/NorwegianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from norwegian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,32 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from norwegian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {+ new Among("", -1, 1),+ new Among("ind", 0, -1),+ new Among("kk", 0, -1),+ new Among("nk", 0, -1),+ new Among("amm", 0, -1),+ new Among("omm", 0, -1),+ new Among("kap", 0, -1),+ new Among("skap", 6, 1),+ new Among("pp", 0, -1),+ new Among("lt", 0, -1),+ new Among("ast", 0, -1),+ new Among("\u00F8st", 0, -1),+ new Among("v", 0, -1),+ new Among("hav", 12, 1),+ new Among("giv", 12, 1)+ };++ private static final Among[] a_1 = {new Among("a", -1, 1),new Among("e", -1, 1),new Among("ede", 1, 1),@@ -23,13 +41,13 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ane", 1, 1),new Among("ene", 1, 1),new Among("hetene", 6, 1),- new Among("erte", 1, 3),+ new Among("erte", 1, 4),new Among("en", -1, 1),new Among("heten", 9, 1),new Among("ar", -1, 1),new Among("er", -1, 1),new Among("heter", 12, 1),- new Among("s", -1, 2),+ new Among("s", -1, 3),new Among("as", 14, 1),new Among("es", 14, 1),new Among("edes", 16, 1),@@ -38,17 +56,17 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("hetenes", 19, 1),new Among("ens", 14, 1),new Among("hetens", 21, 1),- new Among("ers", 14, 1),+ new Among("ers", 14, 2),new Among("ets", 14, 1),new Among("et", -1, 1),new Among("het", 25, 1),- new Among("ert", -1, 3),+ new Among("ert", -1, 4),new Among("ast", -1, 1)};- private static final Among a_1[] = {new Among("dt", -1, -1), new Among("vt", -1, -1)};+ private static final Among[] a_2 = {new Among("dt", -1, -1), new Among("vt", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_3 = {new Among("leg", -1, 1),new Among("eleg", 0, 1),new Among("ig", -1, 1),@@ -62,14 +80,14 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("hetslov", 9, 1)};- private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 0, 128};+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 48, 2, 142};- private static final char g_s_ending[] = {119, 125, 149, 1};+ private static final char[] g_s_ending = {119, 125, 148, 1};- private int I_x;private int I_p1;private boolean r_mark_regions() {+ int I_x;I_p1 = limit;int v_1 = cursor;{@@ -81,42 +99,19 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {}I_x = cursor;cursor = v_1;- golab0:- while (true) {- int v_2 = cursor;- lab1:- {- if (!(in_grouping(g_v, 97, 248))) {- break lab1;- }- cursor = v_2;- break golab0;- }- cursor = v_2;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 248)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_v, 97, 248))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 248)) {+ return false;}+ cursor++;I_p1 = cursor;- lab4:+ lab0:{if (I_p1 >= I_x) {- break lab4;+ break lab0;}I_p1 = I_x;}@@ -128,24 +123,32 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_0);+ among_var = find_among_b(a_1);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_del();break;case 2:+ among_var = find_among_b(a_0);+ switch (among_var) {+ case 1:+ slice_del();+ break;+ }+ break;+ case 3:lab0:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab1:{if (!(in_grouping_b(g_s_ending, 98, 122))) {@@ -153,7 +156,26 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab0;}- cursor = limit - v_3;+ cursor = limit - v_2;+ lab2:+ {+ if (!(eq_s_b("r"))) {+ break lab2;+ }+ {+ int v_3 = limit - cursor;+ lab3:+ {+ if (!(eq_s_b("e"))) {+ break lab3;+ }+ break lab2;+ }+ cursor = limit - v_3;+ }+ break lab0;+ }+ cursor = limit - v_2;if (!(eq_s_b("k"))) {return false;}@@ -163,7 +185,7 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {}slice_del();break;- case 3:+ case 4:slice_from("er");break;}@@ -175,15 +197,15 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_3 = limit_backward;+ int v_2 = limit_backward;limit_backward = I_p1;ket = cursor;- if (find_among_b(a_1) == 0) {- limit_backward = v_3;+ if (find_among_b(a_2) == 0) {+ limit_backward = v_2;return false;}bra = cursor;- limit_backward = v_3;+ limit_backward = v_2;cursor = limit - v_1;if (cursor <= limit_backward) {return false;@@ -198,15 +220,15 @@ public class NorwegianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- if (find_among_b(a_2) == 0) {- limit_backward = v_2;+ if (find_among_b(a_3) == 0) {+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;slice_del();return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PolishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PolishStemmer.javanew file mode 100644index 00000000000..5b16f1b2f06--- /dev/null+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PolishStemmer.java@@ -0,0 +1,344 @@+// Generated from polish.sbl by Snowball 3.0.0 - https://snowballstem.org/++package org.tartarus.snowball.ext;++import org.tartarus.snowball.Among;++/**+ * This class implements the stemming algorithm defined by a snowball script.+ *+ * <p>Generated from polish.sbl by Snowball 3.0.0 - https://snowballstem.org/+ */+@SuppressWarnings("unused")+public class PolishStemmer extends org.tartarus.snowball.SnowballStemmer {++ private static final long serialVersionUID = 1L;+ private static final java.lang.invoke.MethodHandles.Lookup methodObject =+ java.lang.invoke.MethodHandles.lookup();++ private static final Among[] a_0 = {+ new Among("by\u015Bcie", -1, 1),+ new Among("bym", -1, 1),+ new Among("by", -1, 1),+ new Among("by\u015Bmy", -1, 1),+ new Among("by\u015B", -1, 1)+ };++ private static final Among[] a_1 = {+ new Among("\u0105c", -1, 1),+ new Among("aj\u0105c", 0, 1),+ new Among("sz\u0105c", 0, 2),+ new Among("sz", -1, 1),+ new Among("iejsz", 3, 1)+ };++ private static final Among[] a_2 = {+ new Among("a", -1, 1, "r_R1", methodObject),+ new Among("\u0105ca", 0, 1),+ new Among("aj\u0105ca", 1, 1),+ new Among("sz\u0105ca", 1, 2),+ new Among("ia", 0, 1, "r_R1", methodObject),+ new Among("sza", 0, 1),+ new Among("iejsza", 5, 1),+ new Among("a\u0142a", 0, 1),+ new Among("ia\u0142a", 7, 1),+ new Among("i\u0142a", 0, 1),+ new Among("\u0105c", -1, 1),+ new Among("aj\u0105c", 10, 1),+ new Among("e", -1, 1, "r_R1", methodObject),+ new Among("\u0105ce", 12, 1),+ new Among("aj\u0105ce", 13, 1),+ new Among("sz\u0105ce", 13, 2),+ new Among("ie", 12, 1, "r_R1", methodObject),+ new Among("cie", 16, 1),+ new Among("acie", 17, 1),+ new Among("ecie", 17, 1),+ new Among("icie", 17, 1),+ new Among("ajcie", 17, 1),+ new Among("li\u015Bcie", 17, 4),+ new Among("ali\u015Bcie", 22, 1),+ new Among("ieli\u015Bcie", 22, 1),+ new Among("ili\u015Bcie", 22, 1),+ new Among("\u0142y\u015Bcie", 17, 4),+ new Among("a\u0142y\u015Bcie", 26, 1),+ new Among("ia\u0142y\u015Bcie", 27, 1),+ new Among("i\u0142y\u015Bcie", 26, 1),+ new Among("sze", 12, 1),+ new Among("iejsze", 30, 1),+ new Among("ach", -1, 1, "r_R1", methodObject),+ new Among("iach", 32, 1, "r_R1", methodObject),+ new Among("ich", -1, 5),+ new Among("ych", -1, 5),+ new Among("i", -1, 1, "r_R1", methodObject),+ new Among("ali", 36, 1),+ new Among("ieli", 36, 1),+ new Among("ili", 36, 1),+ new Among("ami", 36, 1, "r_R1", methodObject),+ new Among("iami", 40, 1, "r_R1", methodObject),+ new Among("imi", 36, 5),+ new Among("ymi", 36, 5),+ new Among("owi", 36, 1, "r_R1", methodObject),+ new Among("iowi", 44, 1, "r_R1", methodObject),+ new Among("aj", -1, 1),+ new Among("ej", -1, 5),+ new Among("iej", 47, 5),+ new Among("am", -1, 1),+ new Among("a\u0142am", 49, 1),+ new Among("ia\u0142am", 50, 1),+ new Among("i\u0142am", 49, 1),+ new Among("em", -1, 1, "r_R1", methodObject),+ new Among("iem", 53, 1, "r_R1", methodObject),+ new Among("a\u0142em", 53, 1),+ new Among("ia\u0142em", 55, 1),+ new Among("i\u0142em", 53, 1),+ new Among("im", -1, 5),+ new Among("om", -1, 1, "r_R1", methodObject),+ new Among("iom", 59, 1, "r_R1", methodObject),+ new Among("ym", -1, 5),+ new Among("o", -1, 1, "r_R1", methodObject),+ new Among("ego", 62, 5),+ new Among("iego", 63, 5),+ new Among("a\u0142o", 62, 1),+ new Among("ia\u0142o", 65, 1),+ new Among("i\u0142o", 62, 1),+ new Among("u", -1, 1, "r_R1", methodObject),+ new Among("iu", 68, 1, "r_R1", methodObject),+ new Among("emu", 68, 5),+ new Among("iemu", 70, 5),+ new Among("\u00F3w", -1, 1, "r_R1", methodObject),+ new Among("y", -1, 5),+ new Among("amy", 73, 1),+ new Among("emy", 73, 1),+ new Among("imy", 73, 1),+ new Among("li\u015Bmy", 73, 4),+ new Among("ali\u015Bmy", 77, 1),+ new Among("ieli\u015Bmy", 77, 1),+ new Among("ili\u015Bmy", 77, 1),+ new Among("\u0142y\u015Bmy", 73, 4),+ new Among("a\u0142y\u015Bmy", 81, 1),+ new Among("ia\u0142y\u015Bmy", 82, 1),+ new Among("i\u0142y\u015Bmy", 81, 1),+ new Among("a\u0142y", 73, 1),+ new Among("ia\u0142y", 85, 1),+ new Among("i\u0142y", 73, 1),+ new Among("asz", -1, 1),+ new Among("esz", -1, 1),+ new Among("isz", -1, 1),+ new Among("\u0105", -1, 1, "r_R1", methodObject),+ new Among("\u0105c\u0105", 91, 1),+ new Among("aj\u0105c\u0105", 92, 1),+ new Among("sz\u0105c\u0105", 92, 2),+ new Among("i\u0105", 91, 1, "r_R1", methodObject),+ new Among("aj\u0105", 91, 1),+ new Among("sz\u0105", 91, 3),+ new Among("iejsz\u0105", 97, 1),+ new Among("a\u0107", -1, 1),+ new Among("ie\u0107", -1, 1),+ new Among("i\u0107", -1, 1),+ new Among("\u0105\u0107", -1, 1),+ new Among("a\u015B\u0107", -1, 1),+ new Among("e\u015B\u0107", -1, 1),+ new Among("\u0119", -1, 1),+ new Among("sz\u0119", 105, 2),+ new Among("a\u0142", -1, 1),+ new Among("ia\u0142", 107, 1),+ new Among("i\u0142", -1, 1),+ new Among("\u0142a\u015B", -1, 4),+ new Among("a\u0142a\u015B", 110, 1),+ new Among("ia\u0142a\u015B", 111, 1),+ new Among("i\u0142a\u015B", 110, 1),+ new Among("\u0142e\u015B", -1, 4),+ new Among("a\u0142e\u015B", 114, 1),+ new Among("ia\u0142e\u015B", 115, 1),+ new Among("i\u0142e\u015B", 114, 1)+ };++ private static final Among[] a_3 = {+ new Among("\u0107", -1, 1),+ new Among("\u0144", -1, 2),+ new Among("\u015B", -1, 3),+ new Among("\u017A", -1, 4)+ };++ private static final char[] g_v = {+ 17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 16, 0, 0, 1+ };++ private int I_p1;++ private boolean r_mark_regions() {+ I_p1 = limit;+ if (!go_out_grouping(g_v, 97, 281)) {+ return false;+ }+ cursor++;+ if (!go_in_grouping(g_v, 97, 281)) {+ return false;+ }+ cursor++;+ I_p1 = cursor;+ return true;+ }++ private boolean r_R1() {+ return I_p1 <= cursor;+ }++ private boolean r_remove_endings() {+ int among_var;+ int v_1 = limit - cursor;+ lab0:+ {+ if (cursor < I_p1) {+ break lab0;+ }+ int v_2 = limit_backward;+ limit_backward = I_p1;+ ket = cursor;+ if (find_among_b(a_0) == 0) {+ limit_backward = v_2;+ break lab0;+ }+ bra = cursor;+ limit_backward = v_2;+ slice_del();+ }+ cursor = limit - v_1;+ ket = cursor;+ among_var = find_among_b(a_2);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ slice_del();+ break;+ case 2:+ slice_from("s");+ break;+ case 3:+ lab1:+ {+ int v_3 = limit - cursor;+ lab2:+ {+ int v_4 = limit - cursor;+ if (!r_R1()) {+ break lab2;+ }+ cursor = limit - v_4;+ slice_del();+ break lab1;+ }+ cursor = limit - v_3;+ slice_from("s");+ }+ break;+ case 4:+ slice_from("\u0142");+ break;+ case 5:+ slice_del();+ int v_5 = limit - cursor;+ lab3:+ {+ ket = cursor;+ among_var = find_among_b(a_1);+ if (among_var == 0) {+ cursor = limit - v_5;+ break lab3;+ }+ bra = cursor;+ switch (among_var) {+ case 1:+ slice_del();+ break;+ case 2:+ slice_from("s");+ break;+ }+ }+ break;+ }+ return true;+ }++ private boolean r_normalize_consonant() {+ int among_var;+ ket = cursor;+ among_var = find_among_b(a_3);+ if (among_var == 0) {+ return false;+ }+ bra = cursor;+ lab0:+ {+ if (cursor > limit_backward) {+ break lab0;+ }+ return false;+ }+ switch (among_var) {+ case 1:+ slice_from("c");+ break;+ case 2:+ slice_from("n");+ break;+ case 3:+ slice_from("s");+ break;+ case 4:+ slice_from("z");+ break;+ }+ return true;+ }++ @Override+ public boolean stem() {+ int v_1 = cursor;+ r_mark_regions();+ cursor = v_1;+ lab0:+ {+ int v_2 = cursor;+ lab1:+ {+ {+ int c = cursor + 2;+ if (c > limit) {+ break lab1;+ }+ cursor = c;+ }+ limit_backward = cursor;+ cursor = limit;+ if (!r_remove_endings()) {+ break lab1;+ }+ cursor = limit_backward;+ break lab0;+ }+ cursor = v_2;+ limit_backward = cursor;+ cursor = limit;+ if (!r_normalize_consonant()) {+ return false;+ }+ cursor = limit_backward;+ }+ return true;+ }++ @Override+ public boolean equals(Object o) {+ return o instanceof PolishStemmer;+ }++ @Override+ public int hashCode() {+ return PolishStemmer.class.getName().hashCode();+ }+}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.javaindex 0e0081bcfe8..1952ed49515 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PorterStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from porter.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,18 +7,18 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from porter.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("s", -1, 3), new Among("ies", 0, 2), new Among("sses", 0, 1), new Among("ss", 0, -1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 3),new Among("bb", 0, 2),new Among("dd", 0, 2),@@ -34,11 +34,11 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("iz", 0, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ed", -1, 2), new Among("eed", 0, 1), new Among("ing", -1, 2)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("anci", -1, 3),new Among("enci", -1, 2),new Among("abli", -1, 4),@@ -61,7 +61,7 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ousness", -1, 11)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("icate", -1, 2),new Among("ative", -1, 3),new Among("alize", -1, 1),@@ -71,7 +71,7 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ness", -1, 3)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ic", -1, 1),new Among("ance", -1, 1),new Among("ence", -1, 1),@@ -93,11 +93,10 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ou", -1, 1)};- private static final char g_v[] = {17, 65, 16, 1};+ private static final char[] g_v = {17, 65, 16, 1};- private static final char g_v_WXY[] = {1, 17, 65, 208, 1};+ private static final char[] g_v_WXY = {1, 17, 65, 208, 1};- private boolean B_Y_found;private int I_p2;private int I_p1;@@ -108,10 +107,7 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_v, 97, 121))) {return false;}- if (!(out_grouping_b(g_v, 97, 121))) {- return false;- }- return true;+ return out_grouping_b(g_v, 97, 121);}private boolean r_R1() {@@ -161,25 +157,15 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {break;case 2:int v_1 = limit - cursor;- golab0:- while (true) {- lab1:- {- if (!(in_grouping_b(g_v, 97, 121))) {- break lab1;- }- break golab0;- }- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_v, 97, 121)) {+ return false;}+ cursor--;cursor = limit - v_1;slice_del();- int v_3 = limit - cursor;+ int v_2 = limit - cursor;among_var = find_among_b(a_1);- cursor = limit - v_3;+ cursor = limit - v_2;switch (among_var) {case 1:{@@ -201,11 +187,11 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor != I_p1) {return false;}- int v_4 = limit - cursor;+ int v_3 = limit - cursor;if (!r_shortv()) {return false;}- cursor = limit - v_4;+ cursor = limit - v_3;{int c = cursor;insert(cursor, cursor, "e");@@ -236,20 +222,10 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {}}bra = cursor;- golab2:- while (true) {- lab3:- {- if (!(in_grouping_b(g_v, 97, 121))) {- break lab3;- }- break golab2;- }- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_v, 97, 121)) {+ return false;}+ cursor--;slice_from("i");return true;}@@ -379,7 +355,6 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {bra = cursor;lab0:{- int v_1 = limit - cursor;lab1:{if (!r_R2()) {@@ -387,12 +362,11 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab0;}- cursor = limit - v_1;if (!r_R1()) {return false;}{- int v_2 = limit - cursor;+ int v_1 = limit - cursor;lab2:{if (!r_shortv()) {@@ -400,7 +374,7 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {}return false;}- cursor = limit - v_2;+ cursor = limit - v_1;}}slice_del();@@ -425,6 +399,7 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {@Overridepublic boolean stem() {+ boolean B_Y_found;B_Y_found = false;int v_1 = cursor;lab0:@@ -481,130 +456,90 @@ public class PorterStemmer extends org.tartarus.snowball.SnowballStemmer {int v_5 = cursor;lab5:{- golab6:- while (true) {- lab7:- {- if (!(in_grouping(g_v, 97, 121))) {- break lab7;- }- break golab6;- }- if (cursor >= limit) {- break lab5;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 121)) {+ break lab5;}- golab8:- while (true) {- lab9:- {- if (!(out_grouping(g_v, 97, 121))) {- break lab9;- }- break golab8;- }- if (cursor >= limit) {- break lab5;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 121)) {+ break lab5;}+ cursor++;I_p1 = cursor;- golab10:- while (true) {- lab11:- {- if (!(in_grouping(g_v, 97, 121))) {- break lab11;- }- break golab10;- }- if (cursor >= limit) {- break lab5;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 121)) {+ break lab5;}- golab12:- while (true) {- lab13:- {- if (!(out_grouping(g_v, 97, 121))) {- break lab13;- }- break golab12;- }- if (cursor >= limit) {- break lab5;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 121)) {+ break lab5;}+ cursor++;I_p2 = cursor;}cursor = v_5;limit_backward = cursor;cursor = limit;- int v_10 = limit - cursor;+ int v_6 = limit - cursor;r_Step_1a();- cursor = limit - v_10;- int v_11 = limit - cursor;+ cursor = limit - v_6;+ int v_7 = limit - cursor;r_Step_1b();- cursor = limit - v_11;- int v_12 = limit - cursor;+ cursor = limit - v_7;+ int v_8 = limit - cursor;r_Step_1c();- cursor = limit - v_12;- int v_13 = limit - cursor;+ cursor = limit - v_8;+ int v_9 = limit - cursor;r_Step_2();- cursor = limit - v_13;- int v_14 = limit - cursor;+ cursor = limit - v_9;+ int v_10 = limit - cursor;r_Step_3();- cursor = limit - v_14;- int v_15 = limit - cursor;+ cursor = limit - v_10;+ int v_11 = limit - cursor;r_Step_4();- cursor = limit - v_15;- int v_16 = limit - cursor;+ cursor = limit - v_11;+ int v_12 = limit - cursor;r_Step_5a();- cursor = limit - v_16;- int v_17 = limit - cursor;+ cursor = limit - v_12;+ int v_13 = limit - cursor;r_Step_5b();- cursor = limit - v_17;+ cursor = limit - v_13;cursor = limit_backward;- int v_18 = cursor;- lab14:+ int v_14 = cursor;+ lab6:{- if (!(B_Y_found)) {- break lab14;+ if (!B_Y_found) {+ break lab6;}while (true) {- int v_19 = cursor;- lab15:+ int v_15 = cursor;+ lab7:{- golab16:+ golab8:while (true) {- int v_20 = cursor;- lab17:+ int v_16 = cursor;+ lab9:{bra = cursor;if (!(eq_s("Y"))) {- break lab17;+ break lab9;}ket = cursor;- cursor = v_20;- break golab16;+ cursor = v_16;+ break golab8;}- cursor = v_20;+ cursor = v_16;if (cursor >= limit) {- break lab15;+ break lab7;}cursor++;}slice_from("y");continue;}- cursor = v_19;+ cursor = v_15;break;}}- cursor = v_18;+ cursor = v_14;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.javaindex a1fc5c02879..c5ab430bafd 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/PortugueseStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from portuguese.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,37 +7,37 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from portuguese.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 3), new Among("\u00E3", 0, 1), new Among("\u00F5", 0, 2)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 3), new Among("a~", 0, 1), new Among("o~", 0, 2)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ic", -1, -1),new Among("ad", -1, -1),new Among("os", -1, -1),new Among("iv", -1, 1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("ante", -1, 1), new Among("avel", -1, 1), new Among("\u00EDvel", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("ic", -1, 1), new Among("abil", -1, 1), new Among("iv", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ica", -1, 1),new Among("\u00E2ncia", -1, 1),new Among("\u00EAncia", -1, 4),@@ -85,7 +85,7 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ivos", -1, 8)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("ada", -1, 1),new Among("ida", -1, 1),new Among("ia", -1, 1),@@ -208,7 +208,7 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ir\u00E1", -1, 1)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("a", -1, 1),new Among("i", -1, 1),new Among("o", -1, 1),@@ -218,14 +218,14 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F3", -1, 1)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("e", -1, 1),new Among("\u00E7", -1, 2),new Among("\u00E9", -1, 1),new Among("\u00EA", -1, 1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 19, 12, 2};@@ -287,40 +287,20 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 250))) {break lab4;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab4;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab4;}+ cursor++;break lab3;}cursor = v_3;if (!(in_grouping(g_v, 97, 250))) {break lab2;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 250))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab2;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 250)) {+ break lab2;}+ cursor++;}break lab1;}@@ -328,31 +308,21 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 250))) {break lab0;}- lab9:+ lab5:{- int v_6 = cursor;- lab10:+ int v_4 = cursor;+ lab6:{if (!(out_grouping(g_v, 97, 250))) {- break lab10;+ break lab6;}- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab10;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab6;}- break lab9;+ cursor++;+ break lab5;}- cursor = v_6;+ cursor = v_4;if (!(in_grouping(g_v, 97, 250))) {break lab0;}@@ -365,69 +335,29 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {I_pV = cursor;}cursor = v_1;- int v_8 = cursor;- lab13:+ int v_5 = cursor;+ lab7:{- golab14:- while (true) {- lab15:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab15;- }- break golab14;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab7;}- golab16:- while (true) {- lab17:- {- if (!(out_grouping(g_v, 97, 250))) {- break lab17;- }- break golab16;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 250)) {+ break lab7;}+ cursor++;I_p1 = cursor;- golab18:- while (true) {- lab19:- {- if (!(in_grouping(g_v, 97, 250))) {- break lab19;- }- break golab18;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 250)) {+ break lab7;}- golab20:- while (true) {- lab21:- {- if (!(out_grouping(g_v, 97, 250))) {- break lab21;- }- break golab20;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 250)) {+ break lab7;}+ cursor++;I_p2 = cursor;}- cursor = v_8;+ cursor = v_5;return true;}@@ -624,16 +554,16 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;if (find_among_b(a_6) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;slice_del();- limit_backward = v_2;+ limit_backward = v_1;return true;}@@ -712,18 +642,18 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{lab1:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab2:{- int v_5 = limit - cursor;+ int v_4 = limit - cursor;lab3:{- int v_6 = limit - cursor;+ int v_5 = limit - cursor;lab4:{if (!r_standard_suffix()) {@@ -731,13 +661,13 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab3;}- cursor = limit - v_6;+ cursor = limit - v_5;if (!r_verb_suffix()) {break lab2;}}- cursor = limit - v_5;- int v_7 = limit - cursor;+ cursor = limit - v_4;+ int v_6 = limit - cursor;lab5:{ket = cursor;@@ -745,33 +675,33 @@ public class PortugueseStemmer extends org.tartarus.snowball.SnowballStemmer {break lab5;}bra = cursor;- int v_8 = limit - cursor;+ int v_7 = limit - cursor;if (!(eq_s_b("c"))) {break lab5;}- cursor = limit - v_8;+ cursor = limit - v_7;if (!r_RV()) {break lab5;}slice_del();}- cursor = limit - v_7;+ cursor = limit - v_6;break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;if (!r_residual_suffix()) {break lab0;}}}- cursor = limit - v_3;- int v_9 = limit - cursor;+ cursor = limit - v_2;+ int v_8 = limit - cursor;r_residual_form();- cursor = limit - v_9;+ cursor = limit - v_8;cursor = limit_backward;- int v_10 = cursor;+ int v_9 = cursor;r_postlude();- cursor = v_10;+ cursor = v_9;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.javaindex 923bb7068de..854e3ebac81 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RomanianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from romanian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,20 +7,20 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from romanian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {new Among("\u015F", -1, 1), new Among("\u0163", -1, 2)};+ private static final Among[] a_0 = {new Among("\u015F", -1, 1), new Among("\u0163", -1, 2)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("", -1, 3), new Among("I", 0, 1), new Among("U", 0, 2)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ea", -1, 3),new Among("a\u021Bia", -1, 7),new Among("aua", -1, 2),@@ -39,7 +39,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("iilor", 14, 4)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("icala", -1, 4),new Among("iciva", -1, 4),new Among("ativa", -1, 5),@@ -88,7 +88,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("itiv\u0103", -1, 6)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("ica", -1, 1),new Among("abila", -1, 1),new Among("ibila", -1, 1),@@ -153,7 +153,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("iv\u0103", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ea", -1, 1),new Among("ia", -1, 1),new Among("esc", -1, 1),@@ -250,7 +250,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("eaz\u0103", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("a", -1, 1),new Among("e", -1, 1),new Among("ie", 1, 1),@@ -258,7 +258,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0103", -1, 1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 32, 0, 0, 4};@@ -393,40 +393,20 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 259))) {break lab4;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 259))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab4;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 259)) {+ break lab4;}+ cursor++;break lab3;}cursor = v_3;if (!(in_grouping(g_v, 97, 259))) {break lab2;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 259))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab2;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 259)) {+ break lab2;}+ cursor++;}break lab1;}@@ -434,31 +414,21 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 259))) {break lab0;}- lab9:+ lab5:{- int v_6 = cursor;- lab10:+ int v_4 = cursor;+ lab6:{if (!(out_grouping(g_v, 97, 259))) {- break lab10;+ break lab6;}- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 259))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab10;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 259)) {+ break lab6;}- break lab9;+ cursor++;+ break lab5;}- cursor = v_6;+ cursor = v_4;if (!(in_grouping(g_v, 97, 259))) {break lab0;}@@ -471,69 +441,29 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {I_pV = cursor;}cursor = v_1;- int v_8 = cursor;- lab13:+ int v_5 = cursor;+ lab7:{- golab14:- while (true) {- lab15:- {- if (!(in_grouping(g_v, 97, 259))) {- break lab15;- }- break golab14;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 259)) {+ break lab7;}- golab16:- while (true) {- lab17:- {- if (!(out_grouping(g_v, 97, 259))) {- break lab17;- }- break golab16;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 259)) {+ break lab7;}+ cursor++;I_p1 = cursor;- golab18:- while (true) {- lab19:- {- if (!(in_grouping(g_v, 97, 259))) {- break lab19;- }- break golab18;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 259)) {+ break lab7;}- golab20:- while (true) {- lab21:- {- if (!(out_grouping(g_v, 97, 259))) {- break lab21;- }- break golab20;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 259)) {+ break lab7;}+ cursor++;I_p2 = cursor;}- cursor = v_8;+ cursor = v_5;return true;}@@ -713,12 +643,12 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;among_var = find_among_b(a_5);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;@@ -726,7 +656,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {case 1:lab0:{- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab1:{if (!(out_grouping_b(g_v, 97, 259))) {@@ -734,9 +664,9 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab0;}- cursor = limit - v_3;+ cursor = limit - v_2;if (!(eq_s_b("u"))) {- limit_backward = v_2;+ limit_backward = v_1;return false;}}@@ -746,7 +676,7 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_del();break;}- limit_backward = v_2;+ limit_backward = v_1;return true;}@@ -766,45 +696,45 @@ public class RomanianStemmer extends org.tartarus.snowball.SnowballStemmer {@Overridepublic boolean stem() {r_norm();- int v_2 = cursor;+ int v_1 = cursor;r_prelude();- cursor = v_2;+ cursor = v_1;r_mark_regions();limit_backward = cursor;cursor = limit;- int v_4 = limit - cursor;+ int v_2 = limit - cursor;r_step_0();- cursor = limit - v_4;- int v_5 = limit - cursor;+ cursor = limit - v_2;+ int v_3 = limit - cursor;r_standard_suffix();- cursor = limit - v_5;- int v_6 = limit - cursor;+ cursor = limit - v_3;+ int v_4 = limit - cursor;lab0:{lab1:{- int v_7 = limit - cursor;+ int v_5 = limit - cursor;lab2:{- if (!(B_standard_suffix_removed)) {+ if (!B_standard_suffix_removed) {break lab2;}break lab1;}- cursor = limit - v_7;+ cursor = limit - v_5;if (!r_verb_suffix()) {break lab0;}}}- cursor = limit - v_6;- int v_8 = limit - cursor;+ cursor = limit - v_4;+ int v_6 = limit - cursor;r_vowel_suffix();- cursor = limit - v_8;+ cursor = limit - v_6;cursor = limit_backward;- int v_9 = cursor;+ int v_7 = cursor;r_postlude();- cursor = v_9;+ cursor = v_7;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.javaindex f00490517a7..10db0a73596 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/RussianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from russian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from russian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0432", -1, 1),new Among("\u0438\u0432", 0, 2),new Among("\u044B\u0432", 0, 2),@@ -26,7 +26,7 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u044B\u0432\u0448\u0438\u0441\u044C", 6, 2)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u0435\u0435", -1, 1),new Among("\u0438\u0435", -1, 1),new Among("\u043E\u0435", -1, 1),@@ -55,7 +55,7 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u044F\u044F", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u0435\u043C", -1, 1),new Among("\u043D\u043D", -1, 1),new Among("\u0432\u0448", -1, 1),@@ -66,11 +66,11 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0443\u044E\u0449", 6, 2)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u0441\u044C", -1, 1), new Among("\u0441\u044F", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("\u043B\u0430", -1, 1),new Among("\u0438\u043B\u0430", 0, 2),new Among("\u044B\u043B\u0430", 0, 2),@@ -119,7 +119,7 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0443\u044E", 44, 2)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("\u0430", -1, 1),new Among("\u0435\u0432", -1, 1),new Among("\u043E\u0432", -1, 1),@@ -158,18 +158,18 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u044C\u044F", 33, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("\u043E\u0441\u0442", -1, 1), new Among("\u043E\u0441\u0442\u044C", -1, 1)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("\u0435\u0439\u0448\u0435", -1, 1),new Among("\u043D", -1, 2),new Among("\u0435\u0439\u0448", -1, 1),new Among("\u044C", -1, 3)};- private static final char g_v[] = {33, 65, 8, 232};+ private static final char[] g_v = {33, 65, 8, 232};private int I_p2;private int I_pV;@@ -180,63 +180,23 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = cursor;lab0:{- golab1:- while (true) {- lab2:- {- if (!(in_grouping(g_v, 1072, 1103))) {- break lab2;- }- break golab1;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_v, 1072, 1103)) {+ break lab0;}+ cursor++;I_pV = cursor;- golab3:- while (true) {- lab4:- {- if (!(out_grouping(g_v, 1072, 1103))) {- break lab4;- }- break golab3;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_in_grouping(g_v, 1072, 1103)) {+ break lab0;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 1072, 1103))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_out_grouping(g_v, 1072, 1103)) {+ break lab0;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 1072, 1103))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 1072, 1103)) {+ break lab0;}+ cursor++;I_p2 = cursor;}cursor = v_1;@@ -477,14 +437,14 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_6 = limit_backward;+ int v_4 = limit_backward;limit_backward = I_pV;- int v_7 = limit - cursor;+ int v_5 = limit - cursor;lab4:{lab5:{- int v_8 = limit - cursor;+ int v_6 = limit - cursor;lab6:{if (!r_perfective_gerund()) {@@ -492,18 +452,18 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab5;}- cursor = limit - v_8;- int v_9 = limit - cursor;+ cursor = limit - v_6;+ int v_7 = limit - cursor;lab7:{if (!r_reflexive()) {- cursor = limit - v_9;+ cursor = limit - v_7;break lab7;}}lab8:{- int v_10 = limit - cursor;+ int v_8 = limit - cursor;lab9:{if (!r_adjectival()) {@@ -511,7 +471,7 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab8;}- cursor = limit - v_10;+ cursor = limit - v_8;lab10:{if (!r_verb()) {@@ -519,32 +479,32 @@ public class RussianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab8;}- cursor = limit - v_10;+ cursor = limit - v_8;if (!r_noun()) {break lab4;}}}}- cursor = limit - v_7;- int v_11 = limit - cursor;+ cursor = limit - v_5;+ int v_9 = limit - cursor;lab11:{ket = cursor;if (!(eq_s_b("\u0438"))) {- cursor = limit - v_11;+ cursor = limit - v_9;break lab11;}bra = cursor;slice_del();}- int v_12 = limit - cursor;+ int v_10 = limit - cursor;r_derivational();- cursor = limit - v_12;- int v_13 = limit - cursor;+ cursor = limit - v_10;+ int v_11 = limit - cursor;r_tidy_up();- cursor = limit - v_13;- limit_backward = v_6;+ cursor = limit - v_11;+ limit_backward = v_4;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.javaindex 736784b5927..d062bf3cdb6 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SerbianStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from serbian.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from serbian.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0430", -1, 1),new Among("\u0431", -1, 2),new Among("\u0432", -1, 3),@@ -47,7 +47,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u045F", -1, 29)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("daba", -1, 73),new Among("ajaca", -1, 12),new Among("ejaca", -1, 14),@@ -180,7 +180,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("o\u0161\u0107u", -1, 71)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("aca", -1, 124),new Among("eca", -1, 125),new Among("uca", -1, 126),@@ -2218,7 +2218,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ro\u0161i\u0161", 2029, 90)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("a", -1, 1),new Among("oga", 0, 1),new Among("ama", 0, 1),@@ -2247,16 +2247,16 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("enu", 24, 1)};- private static final char g_v[] = {17, 65, 16};+ private static final char[] g_v = {17, 65, 16};- private static final char g_sa[] = {65, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 128};+ private static final char[] g_sa = {65, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 128};- private static final char g_ca[] = {+ private static final char[] g_ca = {119, 95, 23, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 136, 0, 0, 0, 0, 0, 0, 0, 0,0, 128, 0, 0, 0, 16};- private static final char g_rg[] = {1};+ private static final char[] g_rg = {1};private int I_p1;private boolean B_no_diacritics;@@ -2515,111 +2515,71 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = cursor;lab0:{- golab1:- while (true) {- lab2:- {- if (!(in_grouping(g_sa, 263, 382))) {- break lab2;- }- break golab1;- }- if (cursor >= limit) {- break lab0;- }- cursor++;+ if (!go_out_grouping(g_sa, 263, 382)) {+ break lab0;}+ cursor++;B_no_diacritics = false;}cursor = v_1;I_p1 = limit;- int v_3 = cursor;- lab3:+ int v_2 = cursor;+ lab1:{- golab4:- while (true) {- lab5:- {- if (!(in_grouping(g_v, 97, 117))) {- break lab5;- }- break golab4;- }- if (cursor >= limit) {- break lab3;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 117)) {+ break lab1;}+ cursor++;I_p1 = cursor;if (I_p1 >= 2) {- break lab3;+ break lab1;}- golab6:- while (true) {- lab7:- {- if (!(out_grouping(g_v, 97, 117))) {- break lab7;- }- break golab6;- }- if (cursor >= limit) {- break lab3;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 117)) {+ break lab1;}+ cursor++;I_p1 = cursor;}- cursor = v_3;- int v_6 = cursor;- lab8:+ cursor = v_2;+ int v_3 = cursor;+ lab2:{- golab9:+ golab3:while (true) {- lab10:+ lab4:{if (!(eq_s("r"))) {- break lab10;+ break lab4;}- break golab9;+ break golab3;}if (cursor >= limit) {- break lab8;+ break lab2;}cursor++;}- lab11:+ lab5:{- int v_8 = cursor;- lab12:+ int v_4 = cursor;+ lab6:{if (cursor < 2) {- break lab12;+ break lab6;}- break lab11;+ break lab5;}- cursor = v_8;- golab13:- while (true) {- lab14:- {- if (!(out_grouping(g_rg, 114, 114))) {- break lab14;- }- break golab13;- }- if (cursor >= limit) {- break lab8;- }- cursor++;+ cursor = v_4;+ if (!go_in_grouping(g_rg, 114, 114)) {+ break lab2;}+ cursor++;}if ((I_p1 - cursor) <= 1) {- break lab8;+ break lab2;}I_p1 = cursor;}- cursor = v_6;+ cursor = v_3;return true;}@@ -2655,7 +2615,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("\u010Dajni");break;case 7:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("cajni");@@ -2730,7 +2690,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("du\u0161ni");break;case 31:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("dusni");@@ -2796,7 +2756,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("\u0161avi");break;case 52:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("savi");@@ -2808,7 +2768,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("a\u010Dka");break;case 55:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("acka");@@ -2817,7 +2777,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("u\u0161ka");break;case 57:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("uska");@@ -2844,7 +2804,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("ti\u010Dni");break;case 65:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ticni");@@ -2868,7 +2828,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("osti");break;case 72:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("osti");@@ -2928,7 +2888,7 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("a\u0161ni");break;case 91:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("asni");@@ -3310,265 +3270,265 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("at");break;case 121:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("luc");break;case 122:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("snj");break;case 123:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("os");break;case 124:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ac");break;case 125:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ec");break;case 126:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("uc");break;case 127:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("rosi");break;case 128:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("aca");break;case 129:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("jas");break;case 130:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("tas");break;case 131:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("gas");break;case 132:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("nas");break;case 133:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("kas");break;case 134:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("vas");break;case 135:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("bas");break;case 136:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("as");break;case 137:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("cin");break;case 138:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("astaj");break;case 139:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("istaj");break;case 140:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ostaj");break;case 141:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("asta");break;case 142:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ista");break;case 143:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("osta");break;case 144:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ava");break;case 145:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("eva");break;case 146:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("iva");break;case 147:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("uva");break;case 148:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ova");break;case 149:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("jeti");break;case 150:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("inj");break;case 151:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ist");break;case 152:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("es");break;case 153:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("et");break;case 154:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("is");break;case 155:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ir");break;case 156:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ur");break;case 157:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("uj");break;case 158:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ni");break;case 159:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("sn");break;case 160:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("ta");break;case 161:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("a");break;case 162:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("i");break;case 163:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("e");break;case 164:- if (!(B_no_diacritics)) {+ if (!B_no_diacritics) {return false;}slice_from("n");@@ -3597,15 +3557,15 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_4 = limit - cursor;+ int v_1 = limit - cursor;r_Step_1();- cursor = limit - v_4;- int v_5 = limit - cursor;+ cursor = limit - v_1;+ int v_2 = limit - cursor;lab0:{lab1:{- int v_6 = limit - cursor;+ int v_3 = limit - cursor;lab2:{if (!r_Step_2()) {@@ -3613,13 +3573,13 @@ public class SerbianStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_6;+ cursor = limit - v_3;if (!r_Step_3()) {break lab0;}}}- cursor = limit - v_5;+ cursor = limit - v_2;cursor = limit_backward;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.javaindex e04cc28f30e..2ad29d02c90 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SpanishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from spanish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from spanish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("", -1, 6),new Among("\u00E1", 0, 1),new Among("\u00E9", 0, 2),@@ -23,7 +23,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00FA", 0, 5)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("la", -1, -1),new Among("sela", 0, -1),new Among("le", -1, -1),@@ -39,7 +39,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("nos", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ando", -1, 6),new Among("iendo", -1, 6),new Among("yendo", -1, 7),@@ -53,22 +53,22 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00EDr", -1, 5)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("ic", -1, -1),new Among("ad", -1, -1),new Among("os", -1, -1),new Among("iv", -1, 1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("able", -1, 1), new Among("ible", -1, 1), new Among("ante", -1, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("ic", -1, 1), new Among("abil", -1, 1), new Among("iv", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("ica", -1, 1),new Among("ancia", -1, 2),new Among("encia", -1, 5),@@ -84,6 +84,8 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ante", -1, 2),new Among("mente", -1, 7),new Among("amente", 13, 6),+ new Among("acion", -1, 2),+ new Among("ucion", -1, 4),new Among("aci\u00F3n", -1, 2),new Among("uci\u00F3n", -1, 4),new Among("ico", -1, 1),@@ -117,7 +119,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("ivos", -1, 9)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("ya", -1, 1),new Among("ye", -1, 1),new Among("yan", -1, 1),@@ -132,7 +134,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("y\u00F3", -1, 1)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("aba", -1, 2),new Among("ada", -1, 2),new Among("ida", -1, 2),@@ -231,7 +233,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("i\u00F3", -1, 2)};- private static final Among a_9[] = {+ private static final Among[] a_9 = {new Among("a", -1, 1),new Among("e", -1, 2),new Among("o", -1, 1),@@ -242,7 +244,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F3", -1, 1)};- private static final char g_v[] = {+ private static final char[] g_v = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 17, 4, 10};@@ -273,40 +275,20 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 252))) {break lab4;}- golab5:- while (true) {- lab6:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab6;- }- break golab5;- }- if (cursor >= limit) {- break lab4;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab4;}+ cursor++;break lab3;}cursor = v_3;if (!(in_grouping(g_v, 97, 252))) {break lab2;}- golab7:- while (true) {- lab8:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab8;- }- break golab7;- }- if (cursor >= limit) {- break lab2;- }- cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ break lab2;}+ cursor++;}break lab1;}@@ -314,31 +296,21 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping(g_v, 97, 252))) {break lab0;}- lab9:+ lab5:{- int v_6 = cursor;- lab10:+ int v_4 = cursor;+ lab6:{if (!(out_grouping(g_v, 97, 252))) {- break lab10;+ break lab6;}- golab11:- while (true) {- lab12:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab12;- }- break golab11;- }- if (cursor >= limit) {- break lab10;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab6;}- break lab9;+ cursor++;+ break lab5;}- cursor = v_6;+ cursor = v_4;if (!(in_grouping(g_v, 97, 252))) {break lab0;}@@ -351,69 +323,29 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {I_pV = cursor;}cursor = v_1;- int v_8 = cursor;- lab13:+ int v_5 = cursor;+ lab7:{- golab14:- while (true) {- lab15:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab15;- }- break golab14;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab7;}- golab16:- while (true) {- lab17:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab17;- }- break golab16;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ break lab7;}+ cursor++;I_p1 = cursor;- golab18:- while (true) {- lab19:- {- if (!(in_grouping(g_v, 97, 252))) {- break lab19;- }- break golab18;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 252)) {+ break lab7;}- golab20:- while (true) {- lab21:- {- if (!(out_grouping(g_v, 97, 252))) {- break lab21;- }- break golab20;- }- if (cursor >= limit) {- break lab13;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 252)) {+ break lab7;}+ cursor++;I_p2 = cursor;}- cursor = v_8;+ cursor = v_5;return true;}@@ -679,15 +611,15 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;if (find_among_b(a_7) == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;if (!(eq_s_b("u"))) {return false;}@@ -700,31 +632,31 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_pV) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_pV;ket = cursor;among_var = find_among_b(a_8);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:- int v_3 = limit - cursor;+ int v_2 = limit - cursor;lab0:{if (!(eq_s_b("u"))) {- cursor = limit - v_3;+ cursor = limit - v_2;break lab0;}- int v_4 = limit - cursor;+ int v_3 = limit - cursor;if (!(eq_s_b("g"))) {- cursor = limit - v_3;+ cursor = limit - v_2;break lab0;}- cursor = limit - v_4;+ cursor = limit - v_3;}bra = cursor;slice_del();@@ -787,15 +719,15 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {r_mark_regions();limit_backward = cursor;cursor = limit;- int v_2 = limit - cursor;+ int v_1 = limit - cursor;r_attached_pronoun();- cursor = limit - v_2;- int v_3 = limit - cursor;+ cursor = limit - v_1;+ int v_2 = limit - cursor;lab0:{lab1:{- int v_4 = limit - cursor;+ int v_3 = limit - cursor;lab2:{if (!r_standard_suffix()) {@@ -803,7 +735,7 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;lab3:{if (!r_y_verb_suffix()) {@@ -811,20 +743,20 @@ public class SpanishStemmer extends org.tartarus.snowball.SnowballStemmer {}break lab1;}- cursor = limit - v_4;+ cursor = limit - v_3;if (!r_verb_suffix()) {break lab0;}}}- cursor = limit - v_3;- int v_5 = limit - cursor;+ cursor = limit - v_2;+ int v_4 = limit - cursor;r_residual_suffix();- cursor = limit - v_5;+ cursor = limit - v_4;cursor = limit_backward;- int v_6 = cursor;+ int v_5 = cursor;r_postlude();- cursor = v_6;+ cursor = v_5;return true;}diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.javaindex fd210747067..688e63fa2fa 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/SwedishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from swedish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,38 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from swedish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {+ new Among("fab", -1, -1),+ new Among("h", -1, -1),+ new Among("pak", -1, -1),+ new Among("rak", -1, -1),+ new Among("stak", -1, -1),+ new Among("kom", -1, -1),+ new Among("iet", -1, -1),+ new Among("cit", -1, -1),+ new Among("dit", -1, -1),+ new Among("alit", -1, -1),+ new Among("ilit", -1, -1),+ new Among("mit", -1, -1),+ new Among("nit", -1, -1),+ new Among("pit", -1, -1),+ new Among("rit", -1, -1),+ new Among("sit", -1, -1),+ new Among("tit", -1, -1),+ new Among("uit", -1, -1),+ new Among("ivit", -1, -1),+ new Among("kvit", -1, -1),+ new Among("xit", -1, -1)+ };++ private static final Among[] a_1 = {new Among("a", -1, 1),new Among("arna", 0, 1),new Among("erna", 0, 1),@@ -49,12 +73,13 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("hetens", 29, 1),new Among("erns", 21, 1),new Among("at", -1, 1),- new Among("andet", -1, 1),- new Among("het", -1, 1),+ new Among("et", -1, 3),+ new Among("andet", 34, 1),+ new Among("het", 34, 1),new Among("ast", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_2 = {new Among("dd", -1, -1),new Among("gd", -1, -1),new Among("nn", -1, -1),@@ -64,7 +89,7 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("tt", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_3 = {new Among("ig", -1, 1),new Among("lig", 0, 1),new Among("els", -1, 1),@@ -72,16 +97,16 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u00F6st", -1, 2)};- private static final char g_v[] = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 32};+ private static final char[] g_v = {17, 65, 16, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 0, 32};- private static final char g_s_ending[] = {119, 127, 149};+ private static final char[] g_s_ending = {119, 127, 149};- private static final char g_ost_ending[] = {173, 58};+ private static final char[] g_ost_ending = {173, 58};- private int I_x;private int I_p1;private boolean r_mark_regions() {+ int I_x;I_p1 = limit;int v_1 = cursor;{@@ -93,69 +118,98 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {}I_x = cursor;cursor = v_1;- golab0:- while (true) {- int v_2 = cursor;- lab1:- {- if (!(in_grouping(g_v, 97, 246))) {- break lab1;- }- cursor = v_2;- break golab0;- }- cursor = v_2;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_v, 97, 246)) {+ return false;}- golab2:- while (true) {- lab3:- {- if (!(out_grouping(g_v, 97, 246))) {- break lab3;- }- break golab2;- }- if (cursor >= limit) {- return false;- }- cursor++;+ cursor++;+ if (!go_in_grouping(g_v, 97, 246)) {+ return false;}+ cursor++;I_p1 = cursor;- lab4:+ lab0:{if (I_p1 >= I_x) {- break lab4;+ break lab0;}I_p1 = I_x;}return true;}+ private boolean r_et_condition() {+ int v_1 = limit - cursor;+ if (!(out_grouping_b(g_v, 97, 246))) {+ return false;+ }+ if (!(in_grouping_b(g_v, 97, 246))) {+ return false;+ }+ lab0:+ {+ if (cursor > limit_backward) {+ break lab0;+ }+ return false;+ }+ cursor = limit - v_1;+ {+ int v_2 = limit - cursor;+ lab1:+ {+ if (find_among_b(a_0) == 0) {+ break lab1;+ }+ return false;+ }+ cursor = limit - v_2;+ }+ return true;+ }+private boolean r_main_suffix() {int among_var;if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_0);+ among_var = find_among_b(a_1);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_del();break;case 2:- if (!(in_grouping_b(g_s_ending, 98, 121))) {+ lab0:+ {+ int v_2 = limit - cursor;+ lab1:+ {+ if (!(eq_s_b("et"))) {+ break lab1;+ }+ if (!r_et_condition()) {+ break lab1;+ }+ bra = cursor;+ break lab0;+ }+ cursor = limit - v_2;+ if (!(in_grouping_b(g_s_ending, 98, 121))) {+ return false;+ }+ }+ slice_del();+ break;+ case 3:+ if (!r_et_condition()) {return false;}slice_del();@@ -168,23 +222,23 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;- int v_3 = limit - cursor;- if (find_among_b(a_1) == 0) {- limit_backward = v_2;+ int v_2 = limit - cursor;+ if (find_among_b(a_2) == 0) {+ limit_backward = v_1;return false;}- cursor = limit - v_3;+ cursor = limit - v_2;ket = cursor;if (cursor <= limit_backward) {- limit_backward = v_2;+ limit_backward = v_1;return false;}cursor--;bra = cursor;slice_del();- limit_backward = v_2;+ limit_backward = v_1;return true;}@@ -193,16 +247,16 @@ public class SwedishStemmer extends org.tartarus.snowball.SnowballStemmer {if (cursor < I_p1) {return false;}- int v_2 = limit_backward;+ int v_1 = limit_backward;limit_backward = I_p1;ket = cursor;- among_var = find_among_b(a_2);+ among_var = find_among_b(a_3);if (among_var == 0) {- limit_backward = v_2;+ limit_backward = v_1;return false;}bra = cursor;- limit_backward = v_2;+ limit_backward = v_1;switch (among_var) {case 1:slice_del();diff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.javaindex bdc8b013ebd..04e3117ae14 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TamilStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from tamil.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,21 +7,21 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from tamil.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u0BB5\u0BC1", -1, 3),new Among("\u0BB5\u0BC2", -1, 4),new Among("\u0BB5\u0BCA", -1, 2),new Among("\u0BB5\u0BCB", -1, 1)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u0B95", -1, -1),new Among("\u0B99", -1, -1),new Among("\u0B9A", -1, -1),@@ -34,11 +34,11 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB5", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u0BBF", -1, -1), new Among("\u0BC0", -1, -1), new Among("\u0BC8", -1, -1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -49,11 +49,11 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC8", -1, -1)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("", -1, 2), new Among("\u0BC8", 0, 1), new Among("\u0BCD", 0, 1)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("\u0BA8\u0BCD\u0BA4", -1, 1),new Among("\u0BAF", -1, 1),new Among("\u0BB5", -1, 1),@@ -73,7 +73,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB5\u0BCD", -1, 1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("\u0B95", -1, -1),new Among("\u0B9A", -1, -1),new Among("\u0B9F", -1, -1),@@ -82,7 +82,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB1", -1, -1)};- private static final Among a_7[] = {+ private static final Among[] a_7 = {new Among("\u0B95", -1, -1),new Among("\u0B9A", -1, -1),new Among("\u0B9F", -1, -1),@@ -91,7 +91,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB1", -1, -1)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("\u0B9E", -1, -1),new Among("\u0BA3", -1, -1),new Among("\u0BA8", -1, -1),@@ -105,7 +105,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB5", -1, -1)};- private static final Among a_9[] = {+ private static final Among[] a_9 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -117,11 +117,11 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BCD", -1, -1)};- private static final Among a_10[] = {+ private static final Among[] a_10 = {new Among("\u0B85", -1, -1), new Among("\u0B87", -1, -1), new Among("\u0B89", -1, -1)};- private static final Among a_11[] = {+ private static final Among[] a_11 = {new Among("\u0B95", -1, -1),new Among("\u0B99", -1, -1),new Among("\u0B9A", -1, -1),@@ -134,7 +134,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB5", -1, -1)};- private static final Among a_12[] = {+ private static final Among[] a_12 = {new Among("\u0B95", -1, -1),new Among("\u0B9A", -1, -1),new Among("\u0B9F", -1, -1),@@ -143,22 +143,22 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB1", -1, -1)};- private static final Among a_13[] = {+ private static final Among[] a_13 = {new Among("\u0B95\u0BB3\u0BCD", -1, 4),new Among("\u0BC1\u0B99\u0BCD\u0B95\u0BB3\u0BCD", 0, 1),new Among("\u0B9F\u0BCD\u0B95\u0BB3\u0BCD", 0, 3),new Among("\u0BB1\u0BCD\u0B95\u0BB3\u0BCD", 0, 2)};- private static final Among a_14[] = {+ private static final Among[] a_14 = {new Among("\u0BBE", -1, -1), new Among("\u0BC7", -1, -1), new Among("\u0BCB", -1, -1)};- private static final Among a_15[] = {+ private static final Among[] a_15 = {new Among("\u0BAA\u0BBF", -1, -1), new Among("\u0BB5\u0BBF", -1, -1)};- private static final Among a_16[] = {+ private static final Among[] a_16 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -169,7 +169,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC8", -1, -1)};- private static final Among a_17[] = {+ private static final Among[] a_17 = {new Among("\u0BAA\u0B9F\u0BCD\u0B9F", -1, 3),new Among("\u0BAA\u0B9F\u0BCD\u0B9F\u0BA3", -1, 3),new Among("\u0BA4\u0BBE\u0BA9", -1, 3),@@ -198,7 +198,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC6\u0BA9\u0BC1\u0BAE\u0BCD", -1, 1)};- private static final Among a_18[] = {+ private static final Among[] a_18 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -209,7 +209,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC8", -1, -1)};- private static final Among a_19[] = {+ private static final Among[] a_19 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -220,7 +220,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC8", -1, -1)};- private static final Among a_20[] = {+ private static final Among[] a_20 = {new Among("\u0BB5\u0BBF\u0B9F", -1, 2),new Among("\u0BC0", -1, 7),new Among("\u0BCA\u0B9F\u0BC1", -1, 2),@@ -245,7 +245,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0B95\u0BC0\u0BB4\u0BCD", -1, 1)};- private static final Among a_21[] = {+ private static final Among[] a_21 = {new Among("\u0B95", -1, -1),new Among("\u0B9A", -1, -1),new Among("\u0B9F", -1, -1),@@ -254,7 +254,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB1", -1, -1)};- private static final Among a_22[] = {+ private static final Among[] a_22 = {new Among("\u0B95", -1, -1),new Among("\u0B9A", -1, -1),new Among("\u0B9F", -1, -1),@@ -263,7 +263,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BB1", -1, -1)};- private static final Among a_23[] = {+ private static final Among[] a_23 = {new Among("\u0B85", -1, -1),new Among("\u0B86", -1, -1),new Among("\u0B87", -1, -1),@@ -278,7 +278,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0B94", -1, -1)};- private static final Among a_24[] = {+ private static final Among[] a_24 = {new Among("\u0BBE", -1, -1),new Among("\u0BBF", -1, -1),new Among("\u0BC0", -1, -1),@@ -289,7 +289,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BC8", -1, -1)};- private static final Among a_25[] = {+ private static final Among[] a_25 = {new Among("\u0B95", -1, 1),new Among("\u0BA4", -1, 1),new Among("\u0BA9", -1, 1),@@ -338,7 +338,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u0BA9\u0BBE\u0BB3\u0BCD", 44, 1)};- private static final Among a_26[] = {+ private static final Among[] a_26 = {new Among("\u0B95\u0BBF\u0BB1", -1, -1),new Among("\u0B95\u0BBF\u0BA9\u0BCD\u0BB1", -1, -1),new Among("\u0BBE\u0BA8\u0BBF\u0BA9\u0BCD\u0BB1", -1, -1),@@ -348,7 +348,6 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {};private boolean B_found_vetrumai_urupu;- private boolean B_found_a_match;private boolean r_has_min_length() {return length > 4;@@ -459,7 +458,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("\u0B9F\u0BC1");break;case 6:- if (!(B_found_vetrumai_urupu)) {+ if (!B_found_vetrumai_urupu) {break lab1;}{@@ -857,17 +856,13 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_remove_tense_suffixes() {- B_found_a_match = true;while (true) {int v_1 = cursor;lab0:{- if (!(B_found_a_match)) {+ if (!r_remove_tense_suffix()) {break lab0;}- int v_2 = cursor;- r_remove_tense_suffix();- cursor = v_2;continue;}cursor = v_1;@@ -877,6 +872,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_remove_tense_suffix() {+ boolean B_found_a_match;int among_var;B_found_a_match = false;if (!r_has_min_length()) {@@ -970,7 +966,7 @@ public class TamilStemmer extends org.tartarus.snowball.SnowballStemmer {cursor = limit - v_7;cursor = limit_backward;r_fix_endings();- return true;+ return B_found_a_match;}@Overridediff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.javaindex 2e859ebca60..36ed9ede937 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/TurkishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from turkish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from turkish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("m", -1, -1),new Among("n", -1, -1),new Among("miz", -1, -1),@@ -27,86 +27,86 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("n\u0131z", -1, -1)};- private static final Among a_1[] = {new Among("leri", -1, -1), new Among("lar\u0131", -1, -1)};+ private static final Among[] a_1 = {new Among("leri", -1, -1), new Among("lar\u0131", -1, -1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("ni", -1, -1),new Among("nu", -1, -1),new Among("n\u00FC", -1, -1),new Among("n\u0131", -1, -1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("in", -1, -1),new Among("un", -1, -1),new Among("\u00FCn", -1, -1),new Among("\u0131n", -1, -1)};- private static final Among a_4[] = {new Among("a", -1, -1), new Among("e", -1, -1)};+ private static final Among[] a_4 = {new Among("a", -1, -1), new Among("e", -1, -1)};- private static final Among a_5[] = {new Among("na", -1, -1), new Among("ne", -1, -1)};+ private static final Among[] a_5 = {new Among("na", -1, -1), new Among("ne", -1, -1)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("da", -1, -1),new Among("ta", -1, -1),new Among("de", -1, -1),new Among("te", -1, -1)};- private static final Among a_7[] = {new Among("nda", -1, -1), new Among("nde", -1, -1)};+ private static final Among[] a_7 = {new Among("nda", -1, -1), new Among("nde", -1, -1)};- private static final Among a_8[] = {+ private static final Among[] a_8 = {new Among("dan", -1, -1),new Among("tan", -1, -1),new Among("den", -1, -1),new Among("ten", -1, -1)};- private static final Among a_9[] = {new Among("ndan", -1, -1), new Among("nden", -1, -1)};+ private static final Among[] a_9 = {new Among("ndan", -1, -1), new Among("nden", -1, -1)};- private static final Among a_10[] = {new Among("la", -1, -1), new Among("le", -1, -1)};+ private static final Among[] a_10 = {new Among("la", -1, -1), new Among("le", -1, -1)};- private static final Among a_11[] = {new Among("ca", -1, -1), new Among("ce", -1, -1)};+ private static final Among[] a_11 = {new Among("ca", -1, -1), new Among("ce", -1, -1)};- private static final Among a_12[] = {+ private static final Among[] a_12 = {new Among("im", -1, -1),new Among("um", -1, -1),new Among("\u00FCm", -1, -1),new Among("\u0131m", -1, -1)};- private static final Among a_13[] = {+ private static final Among[] a_13 = {new Among("sin", -1, -1),new Among("sun", -1, -1),new Among("s\u00FCn", -1, -1),new Among("s\u0131n", -1, -1)};- private static final Among a_14[] = {+ private static final Among[] a_14 = {new Among("iz", -1, -1),new Among("uz", -1, -1),new Among("\u00FCz", -1, -1),new Among("\u0131z", -1, -1)};- private static final Among a_15[] = {+ private static final Among[] a_15 = {new Among("siniz", -1, -1),new Among("sunuz", -1, -1),new Among("s\u00FCn\u00FCz", -1, -1),new Among("s\u0131n\u0131z", -1, -1)};- private static final Among a_16[] = {new Among("lar", -1, -1), new Among("ler", -1, -1)};+ private static final Among[] a_16 = {new Among("lar", -1, -1), new Among("ler", -1, -1)};- private static final Among a_17[] = {+ private static final Among[] a_17 = {new Among("niz", -1, -1),new Among("nuz", -1, -1),new Among("n\u00FCz", -1, -1),new Among("n\u0131z", -1, -1)};- private static final Among a_18[] = {+ private static final Among[] a_18 = {new Among("dir", -1, -1),new Among("tir", -1, -1),new Among("dur", -1, -1),@@ -117,11 +117,11 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("t\u0131r", -1, -1)};- private static final Among a_19[] = {+ private static final Among[] a_19 = {new Among("cas\u0131na", -1, -1), new Among("cesine", -1, -1)};- private static final Among a_20[] = {+ private static final Among[] a_20 = {new Among("di", -1, -1),new Among("ti", -1, -1),new Among("dik", -1, -1),@@ -156,7 +156,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("t\u0131", -1, -1)};- private static final Among a_21[] = {+ private static final Among[] a_21 = {new Among("sa", -1, -1),new Among("se", -1, -1),new Among("sak", -1, -1),@@ -167,261 +167,135 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("sen", -1, -1)};- private static final Among a_22[] = {+ private static final Among[] a_22 = {new Among("mi\u015F", -1, -1),new Among("mu\u015F", -1, -1),new Among("m\u00FC\u015F", -1, -1),new Among("m\u0131\u015F", -1, -1)};- private static final Among a_23[] = {+ private static final Among[] a_23 = {new Among("b", -1, 1), new Among("c", -1, 2), new Among("d", -1, 3), new Among("\u011F", -1, 4)};- private static final char g_vowel[] = {+ private static final char[] g_vowel = {17, 65, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 8, 0, 0, 0, 0, 0, 0, 1};- private static final char g_U[] = {+ private static final char[] g_U = {1, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 1};- private static final char g_vowel1[] = {+ private static final char[] g_vowel1 = {1, 64, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1};- private static final char g_vowel2[] = {+ private static final char[] g_vowel2 = {17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 130};- private static final char g_vowel3[] = {+ private static final char[] g_vowel3 = {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1};- private static final char g_vowel4[] = {17};+ private static final char[] g_vowel4 = {17};- private static final char g_vowel5[] = {65};+ private static final char[] g_vowel5 = {65};- private static final char g_vowel6[] = {65};+ private static final char[] g_vowel6 = {65};private boolean B_continue_stemming_noun_suffixes;private boolean r_check_vowel_harmony() {int v_1 = limit - cursor;- golab0:- while (true) {- int v_2 = limit - cursor;- lab1:- {- if (!(in_grouping_b(g_vowel, 97, 305))) {- break lab1;- }- cursor = limit - v_2;- break golab0;- }- cursor = limit - v_2;- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_vowel, 97, 305)) {+ return false;}- lab2:+ lab0:{- int v_3 = limit - cursor;- lab3:+ int v_2 = limit - cursor;+ lab1:{if (!(eq_s_b("a"))) {- break lab3;+ break lab1;}- golab4:- while (true) {- int v_4 = limit - cursor;- lab5:- {- if (!(in_grouping_b(g_vowel1, 97, 305))) {- break lab5;- }- cursor = limit - v_4;- break golab4;- }- cursor = limit - v_4;- if (cursor <= limit_backward) {- break lab3;- }- cursor--;+ if (!go_out_grouping_b(g_vowel1, 97, 305)) {+ break lab1;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab6:+ cursor = limit - v_2;+ lab2:{if (!(eq_s_b("e"))) {- break lab6;+ break lab2;}- golab7:- while (true) {- int v_5 = limit - cursor;- lab8:- {- if (!(in_grouping_b(g_vowel2, 101, 252))) {- break lab8;- }- cursor = limit - v_5;- break golab7;- }- cursor = limit - v_5;- if (cursor <= limit_backward) {- break lab6;- }- cursor--;+ if (!go_out_grouping_b(g_vowel2, 101, 252)) {+ break lab2;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab9:+ cursor = limit - v_2;+ lab3:{if (!(eq_s_b("\u0131"))) {- break lab9;+ break lab3;}- golab10:- while (true) {- int v_6 = limit - cursor;- lab11:- {- if (!(in_grouping_b(g_vowel3, 97, 305))) {- break lab11;- }- cursor = limit - v_6;- break golab10;- }- cursor = limit - v_6;- if (cursor <= limit_backward) {- break lab9;- }- cursor--;+ if (!go_out_grouping_b(g_vowel3, 97, 305)) {+ break lab3;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab12:+ cursor = limit - v_2;+ lab4:{if (!(eq_s_b("i"))) {- break lab12;+ break lab4;}- golab13:- while (true) {- int v_7 = limit - cursor;- lab14:- {- if (!(in_grouping_b(g_vowel4, 101, 105))) {- break lab14;- }- cursor = limit - v_7;- break golab13;- }- cursor = limit - v_7;- if (cursor <= limit_backward) {- break lab12;- }- cursor--;+ if (!go_out_grouping_b(g_vowel4, 101, 105)) {+ break lab4;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab15:+ cursor = limit - v_2;+ lab5:{if (!(eq_s_b("o"))) {- break lab15;+ break lab5;}- golab16:- while (true) {- int v_8 = limit - cursor;- lab17:- {- if (!(in_grouping_b(g_vowel5, 111, 117))) {- break lab17;- }- cursor = limit - v_8;- break golab16;- }- cursor = limit - v_8;- if (cursor <= limit_backward) {- break lab15;- }- cursor--;+ if (!go_out_grouping_b(g_vowel5, 111, 117)) {+ break lab5;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab18:+ cursor = limit - v_2;+ lab6:{if (!(eq_s_b("\u00F6"))) {- break lab18;+ break lab6;}- golab19:- while (true) {- int v_9 = limit - cursor;- lab20:- {- if (!(in_grouping_b(g_vowel6, 246, 252))) {- break lab20;- }- cursor = limit - v_9;- break golab19;- }- cursor = limit - v_9;- if (cursor <= limit_backward) {- break lab18;- }- cursor--;+ if (!go_out_grouping_b(g_vowel6, 246, 252)) {+ break lab6;}- break lab2;+ break lab0;}- cursor = limit - v_3;- lab21:+ cursor = limit - v_2;+ lab7:{if (!(eq_s_b("u"))) {- break lab21;+ break lab7;}- golab22:- while (true) {- int v_10 = limit - cursor;- lab23:- {- if (!(in_grouping_b(g_vowel5, 111, 117))) {- break lab23;- }- cursor = limit - v_10;- break golab22;- }- cursor = limit - v_10;- if (cursor <= limit_backward) {- break lab21;- }- cursor--;+ if (!go_out_grouping_b(g_vowel5, 111, 117)) {+ break lab7;}- break lab2;+ break lab0;}- cursor = limit - v_3;+ cursor = limit - v_2;if (!(eq_s_b("\u00FC"))) {return false;}- golab24:- while (true) {- int v_11 = limit - cursor;- lab25:- {- if (!(in_grouping_b(g_vowel6, 246, 252))) {- break lab25;- }- cursor = limit - v_11;- break golab24;- }- cursor = limit - v_11;- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_vowel6, 246, 252)) {+ return false;}}cursor = limit - v_1;@@ -449,16 +323,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_3 = limit - cursor;lab2:{- int v_4 = limit - cursor;if (!(eq_s_b("n"))) {break lab2;}- cursor = limit - v_4;return false;}cursor = limit - v_3;}- int v_5 = limit - cursor;+ int v_4 = limit - cursor;if (cursor <= limit_backward) {return false;}@@ -466,7 +338,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_vowel, 97, 305))) {return false;}- cursor = limit - v_5;+ cursor = limit - v_4;}return true;}@@ -492,16 +364,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_3 = limit - cursor;lab2:{- int v_4 = limit - cursor;if (!(eq_s_b("s"))) {break lab2;}- cursor = limit - v_4;return false;}cursor = limit - v_3;}- int v_5 = limit - cursor;+ int v_4 = limit - cursor;if (cursor <= limit_backward) {return false;}@@ -509,7 +379,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_vowel, 97, 305))) {return false;}- cursor = limit - v_5;+ cursor = limit - v_4;}return true;}@@ -535,16 +405,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_3 = limit - cursor;lab2:{- int v_4 = limit - cursor;if (!(eq_s_b("y"))) {break lab2;}- cursor = limit - v_4;return false;}cursor = limit - v_3;}- int v_5 = limit - cursor;+ int v_4 = limit - cursor;if (cursor <= limit_backward) {return false;}@@ -552,7 +420,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_vowel, 97, 305))) {return false;}- cursor = limit - v_5;+ cursor = limit - v_4;}return true;}@@ -578,16 +446,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_3 = limit - cursor;lab2:{- int v_4 = limit - cursor;if (!(in_grouping_b(g_U, 105, 305))) {break lab2;}- cursor = limit - v_4;return false;}cursor = limit - v_3;}- int v_5 = limit - cursor;+ int v_4 = limit - cursor;if (cursor <= limit_backward) {return false;}@@ -595,7 +461,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(out_grouping_b(g_vowel, 97, 305))) {return false;}- cursor = limit - v_5;+ cursor = limit - v_4;}return true;}@@ -604,10 +470,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_0) == 0) {return false;}- if (!r_mark_suffix_with_optional_U_vowel()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_U_vowel();}private boolean r_mark_sU() {@@ -617,17 +480,11 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_U, 105, 305))) {return false;}- if (!r_mark_suffix_with_optional_s_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_s_consonant();}private boolean r_mark_lArI() {- if (find_among_b(a_1) == 0) {- return false;- }- return true;+ return find_among_b(a_1) != 0;}private boolean r_mark_yU() {@@ -637,20 +494,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (!(in_grouping_b(g_U, 105, 305))) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_nU() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_2) == 0) {- return false;- }- return true;+ return find_among_b(a_2) != 0;}private boolean r_mark_nUn() {@@ -660,10 +511,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_3) == 0) {return false;}- if (!r_mark_suffix_with_optional_n_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_n_consonant();}private boolean r_mark_yA() {@@ -673,60 +521,42 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_4) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_nA() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_5) == 0) {- return false;- }- return true;+ return find_among_b(a_5) != 0;}private boolean r_mark_DA() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_6) == 0) {- return false;- }- return true;+ return find_among_b(a_6) != 0;}private boolean r_mark_ndA() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_7) == 0) {- return false;- }- return true;+ return find_among_b(a_7) != 0;}private boolean r_mark_DAn() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_8) == 0) {- return false;- }- return true;+ return find_among_b(a_8) != 0;}private boolean r_mark_ndAn() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_9) == 0) {- return false;- }- return true;+ return find_among_b(a_9) != 0;}private boolean r_mark_ylA() {@@ -736,17 +566,11 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_10) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_ki() {- if (!(eq_s_b("ki"))) {- return false;- }- return true;+ return eq_s_b("ki");}private boolean r_mark_ncA() {@@ -756,10 +580,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_11) == 0) {return false;}- if (!r_mark_suffix_with_optional_n_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_n_consonant();}private boolean r_mark_yUm() {@@ -769,20 +590,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_12) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_sUn() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_13) == 0) {- return false;- }- return true;+ return find_among_b(a_13) != 0;}private boolean r_mark_yUz() {@@ -792,54 +607,36 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_14) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_sUnUz() {- if (find_among_b(a_15) == 0) {- return false;- }- return true;+ return find_among_b(a_15) != 0;}private boolean r_mark_lAr() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_16) == 0) {- return false;- }- return true;+ return find_among_b(a_16) != 0;}private boolean r_mark_nUz() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_17) == 0) {- return false;- }- return true;+ return find_among_b(a_17) != 0;}private boolean r_mark_DUr() {if (!r_check_vowel_harmony()) {return false;}- if (find_among_b(a_18) == 0) {- return false;- }- return true;+ return find_among_b(a_18) != 0;}private boolean r_mark_cAsInA() {- if (find_among_b(a_19) == 0) {- return false;- }- return true;+ return find_among_b(a_19) != 0;}private boolean r_mark_yDU() {@@ -849,20 +646,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_20) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_ysA() {if (find_among_b(a_21) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_ymUs_() {@@ -872,20 +663,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {if (find_among_b(a_22) == 0) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_mark_yken() {if (!(eq_s_b("ken"))) {return false;}- if (!r_mark_suffix_with_optional_y_consonant()) {- return false;- }- return true;+ return r_mark_suffix_with_optional_y_consonant();}private boolean r_stem_nominal_verb_suffixes() {@@ -1894,100 +1679,86 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {return false;}}- golab2:- while (true) {- int v_2 = limit - cursor;- lab3:- {- if (!(in_grouping_b(g_vowel, 97, 305))) {- break lab3;- }- cursor = limit - v_2;- break golab2;- }- cursor = limit - v_2;- if (cursor <= limit_backward) {- return false;- }- cursor--;+ if (!go_out_grouping_b(g_vowel, 97, 305)) {+ return false;}- lab4:+ lab2:{- int v_3 = limit - cursor;- lab5:+ int v_2 = limit - cursor;+ lab3:{- lab6:+ lab4:{- int v_4 = limit - cursor;- lab7:+ int v_3 = limit - cursor;+ lab5:{if (!(eq_s_b("a"))) {- break lab7;+ break lab5;}- break lab6;+ break lab4;}- cursor = limit - v_4;+ cursor = limit - v_3;if (!(eq_s_b("\u0131"))) {- break lab5;+ break lab3;}}slice_from("\u0131");- break lab4;+ break lab2;}- cursor = limit - v_3;- lab8:+ cursor = limit - v_2;+ lab6:{- lab9:+ lab7:{- int v_5 = limit - cursor;- lab10:+ int v_4 = limit - cursor;+ lab8:{if (!(eq_s_b("e"))) {- break lab10;+ break lab8;}- break lab9;+ break lab7;}- cursor = limit - v_5;+ cursor = limit - v_4;if (!(eq_s_b("i"))) {- break lab8;+ break lab6;}}slice_from("i");- break lab4;+ break lab2;}- cursor = limit - v_3;- lab11:+ cursor = limit - v_2;+ lab9:{- lab12:+ lab10:{- int v_6 = limit - cursor;- lab13:+ int v_5 = limit - cursor;+ lab11:{if (!(eq_s_b("o"))) {- break lab13;+ break lab11;}- break lab12;+ break lab10;}- cursor = limit - v_6;+ cursor = limit - v_5;if (!(eq_s_b("u"))) {- break lab11;+ break lab9;}}slice_from("u");- break lab4;+ break lab2;}- cursor = limit - v_3;- lab14:+ cursor = limit - v_2;+ lab12:{- int v_7 = limit - cursor;- lab15:+ int v_6 = limit - cursor;+ lab13:{if (!(eq_s_b("\u00F6"))) {- break lab15;+ break lab13;}- break lab14;+ break lab12;}- cursor = limit - v_7;+ cursor = limit - v_6;if (!(eq_s_b("\u00FC"))) {return false;}@@ -2015,23 +1786,83 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {return true;}- private boolean r_more_than_one_syllable_word() {+ private boolean r_remove_proper_noun_suffix() {int v_1 = cursor;- for (int v_2 = 2; v_2 > 0; v_2--) {- golab0:+ lab0:+ {+ bra = cursor;+ golab1:while (true) {- lab1:+ int v_2 = cursor;+ lab2:{- if (!(in_grouping(g_vowel, 97, 305))) {- break lab1;+ {+ int v_3 = cursor;+ lab3:+ {+ if (!(eq_s("'"))) {+ break lab3;+ }+ break lab2;+ }+ cursor = v_3;}- break golab0;+ cursor = v_2;+ break golab1;}+ cursor = v_2;if (cursor >= limit) {- return false;+ break lab0;}cursor++;}+ ket = cursor;+ slice_del();+ }+ cursor = v_1;+ int v_4 = cursor;+ lab4:+ {+ {+ int c = cursor + 2;+ if (c > limit) {+ break lab4;+ }+ cursor = c;+ }+ golab5:+ while (true) {+ int v_5 = cursor;+ lab6:+ {+ if (!(eq_s("'"))) {+ break lab6;+ }+ cursor = v_5;+ break golab5;+ }+ cursor = v_5;+ if (cursor >= limit) {+ break lab4;+ }+ cursor++;+ }+ bra = cursor;+ cursor = limit;+ ket = cursor;+ slice_del();+ }+ cursor = v_4;+ return true;+ }++ private boolean r_more_than_one_syllable_word() {+ int v_1 = cursor;+ for (int v_2 = 2; v_2 > 0; v_2--) {+ if (!go_out_grouping(g_vowel, 97, 305)) {+ return false;+ }+ cursor++;}cursor = v_1;return true;@@ -2063,6 +1894,7 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {@Overridepublic boolean stem() {+ r_remove_proper_noun_suffix();if (!r_more_than_one_syllable_word()) {return false;}@@ -2071,17 +1903,14 @@ public class TurkishStemmer extends org.tartarus.snowball.SnowballStemmer {int v_1 = limit - cursor;r_stem_nominal_verb_suffixes();cursor = limit - v_1;- if (!(B_continue_stemming_noun_suffixes)) {+ if (!B_continue_stemming_noun_suffixes) {return false;}int v_2 = limit - cursor;r_stem_noun_suffixes();cursor = limit - v_2;cursor = limit_backward;- if (!r_postlude()) {- return false;- }- return true;+ return r_postlude();}@Overridediff --git a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.java b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.javaindex 30bfaee8f90..9e37606e65b 100644--- a/lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.java+++ b/lucene/analysis/common/src/java/org/tartarus/snowball/ext/YiddishStemmer.java@@ -1,4 +1,4 @@-// Generated by Snowball 2.2.0 - https://snowballstem.org/+// Generated from yiddish.sbl by Snowball 3.0.0 - https://snowballstem.org/package org.tartarus.snowball.ext;@@ -7,14 +7,14 @@ import org.tartarus.snowball.Among;/*** This class implements the stemming algorithm defined by a snowball script.*- * <p>Generated by Snowball 2.2.0 - https://snowballstem.org/+ * <p>Generated from yiddish.sbl by Snowball 3.0.0 - https://snowballstem.org/*/@SuppressWarnings("unused")public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {private static final long serialVersionUID = 1L;- private static final Among a_0[] = {+ private static final Among[] a_0 = {new Among("\u05D5\u05D5", -1, 1),new Among("\u05D5\u05D9", -1, 2),new Among("\u05D9\u05D9", -1, 3),@@ -25,7 +25,7 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05E5", -1, 8)};- private static final Among a_1[] = {+ private static final Among[] a_1 = {new Among("\u05D0\u05D3\u05D5\u05E8\u05DB", -1, 1),new Among("\u05D0\u05D4\u05D9\u05E0", -1, 1),new Among("\u05D0\u05D4\u05E2\u05E8", -1, 1),@@ -68,14 +68,14 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05E6\u05E2", -1, 1)};- private static final Among a_2[] = {+ private static final Among[] a_2 = {new Among("\u05D3\u05D6\u05E9", -1, -1),new Among("\u05E9\u05D8\u05E8", -1, -1),new Among("\u05E9\u05D8\u05E9", -1, -1),new Among("\u05E9\u05E4\u05E8", -1, -1)};- private static final Among a_3[] = {+ private static final Among[] a_3 = {new Among("\u05E7\u05DC\u05D9\u05D1", -1, 9),new Among("\u05E8\u05D9\u05D1", -1, 10),new Among("\u05D8\u05E8\u05D9\u05D1", 1, 7),@@ -104,7 +104,7 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05F0\u05D5\u05D8\u05E9", -1, 17)};- private static final Among a_4[] = {+ private static final Among[] a_4 = {new Among("\u05D5\u05E0\u05D2", -1, 1),new Among("\u05E1\u05D8\u05D5", -1, 1),new Among("\u05D8", -1, 1),@@ -186,7 +186,7 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05D5\u05EA", -1, 32)};- private static final Among a_5[] = {+ private static final Among[] a_5 = {new Among("\u05D5\u05E0\u05D2", -1, 1),new Among("\u05E9\u05D0\u05E4\u05D8", -1, 1),new Among("\u05D4\u05F2\u05D8", -1, 1),@@ -195,7 +195,7 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05DC", -1, 2)};- private static final Among a_6[] = {+ private static final Among[] a_6 = {new Among("\u05D9\u05D2", -1, 1),new Among("\u05D9\u05E7", -1, 1),new Among("\u05D3\u05D9\u05E7", 1, 1),@@ -207,13 +207,12 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {new Among("\u05D9\u05E9", -1, 1)};- private static final char g_niked[] = {255, 155, 6};+ private static final char[] g_niked = {255, 155, 6};- private static final char g_vowel[] = {33, 2, 4, 0, 6};+ private static final char[] g_vowel = {33, 2, 4, 0, 6};- private static final char g_consonant[] = {239, 254, 253, 131};+ private static final char[] g_consonant = {239, 254, 253, 131};- private int I_x;private int I_p1;private boolean r_prelude() {@@ -349,6 +348,7 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {}private boolean r_mark_regions() {+ int I_x;I_p1 = limit;int v_1 = cursor;lab0:@@ -374,7 +374,15 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {break lab2;}cursor = v_3;- if (!(eq_s("\u05D1\u05E0"))) {+ lab4:+ {+ if (!(eq_s("\u05D1\u05E0"))) {+ break lab4;+ }+ break lab2;+ }+ cursor = v_3;+ if (cursor < limit) {break lab1;}}@@ -386,73 +394,73 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {slice_from("GE");}int v_4 = cursor;- lab4:+ lab5:{if (find_among(a_1) == 0) {cursor = v_4;- break lab4;+ break lab5;}- lab5:+ lab6:{int v_5 = cursor;- lab6:+ lab7:{int v_6 = cursor;- lab7:+ lab8:{int v_7 = cursor;- lab8:+ lab9:{if (!(eq_s("\u05E6\u05D5\u05D2\u05E0"))) {- break lab8;+ break lab9;}- break lab7;+ break lab8;}cursor = v_7;- lab9:+ lab10:{if (!(eq_s("\u05E6\u05D5\u05E7\u05D8"))) {- break lab9;+ break lab10;}- break lab7;+ break lab8;}cursor = v_7;if (!(eq_s("\u05E6\u05D5\u05E7\u05E0"))) {- break lab6;+ break lab7;}}if (cursor < limit) {- break lab6;+ break lab7;}cursor = v_6;- break lab5;+ break lab6;}cursor = v_5;- lab10:+ lab11:{int v_8 = cursor;if (!(eq_s("\u05D2\u05E2\u05D1\u05E0"))) {- break lab10;+ break lab11;}cursor = v_8;- break lab5;+ break lab6;}cursor = v_5;- lab11:+ lab12:{bra = cursor;if (!(eq_s("\u05D2\u05E2"))) {- break lab11;+ break lab12;}ket = cursor;slice_from("GE");- break lab5;+ break lab6;}cursor = v_5;bra = cursor;if (!(eq_s("\u05E6\u05D5"))) {cursor = v_4;- break lab4;+ break lab5;}ket = cursor;slice_from("TSU");@@ -469,63 +477,43 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {I_x = cursor;cursor = v_9;int v_10 = cursor;- lab12:+ lab13:{if (find_among(a_2) == 0) {cursor = v_10;- break lab12;+ break lab13;}}{int v_11 = cursor;- lab13:+ lab14:{if (!(in_grouping(g_consonant, 1489, 1520))) {- break lab13;+ break lab14;}if (!(in_grouping(g_consonant, 1489, 1520))) {- break lab13;+ break lab14;}if (!(in_grouping(g_consonant, 1489, 1520))) {- break lab13;+ break lab14;}I_p1 = cursor;return false;}cursor = v_11;}- golab14:- while (true) {- int v_12 = cursor;- lab15:- {- if (!(in_grouping(g_vowel, 1488, 1522))) {- break lab15;- }- cursor = v_12;- break golab14;- }- cursor = v_12;- if (cursor >= limit) {- return false;- }- cursor++;+ if (!go_out_grouping(g_vowel, 1488, 1522)) {+ return false;}- while (true) {- lab16:- {- if (!(in_grouping(g_vowel, 1488, 1522))) {- break lab16;- }- continue;- }- break;+ cursor++;+ if (!go_in_grouping(g_vowel, 1488, 1522)) {+ return false;}I_p1 = cursor;- lab17:+ lab15:{if (I_p1 >= I_x) {- break lab17;+ break lab15;}I_p1 = I_x;}@@ -914,9 +902,9 @@ public class YiddishStemmer extends org.tartarus.snowball.SnowballStemmer {@Overridepublic boolean stem() {r_prelude();- int v_2 = cursor;+ int v_1 = cursor;r_mark_regions();- cursor = v_2;+ cursor = v_1;limit_backward = cursor;cursor = limit;r_standard_suffix();diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/nl/TestDutchAnalyzer.java b/lucene/analysis/common/src/test/org/apache/lucene/analysis/nl/TestDutchAnalyzer.javaindex 3c5db968fc4..207c5d307e0 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/nl/TestDutchAnalyzer.java+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/nl/TestDutchAnalyzer.java@@ -31,98 +31,98 @@ public class TestDutchAnalyzer extends BaseTokenStreamTestCase {public void testWithSnowballExamples() throws Exception {check("lichaamsziek", "lichaamsziek");- check("lichamelijk", "licham");- check("lichamelijke", "licham");- check("lichamelijkheden", "licham");- check("lichamen", "licham");+ check("lichamelijk", "lichamelijk");+ check("lichamelijke", "lichamelijk");+ check("lichamelijkheden", "lichamelijk");+ check("lichamen", "lichaam");check("lichere", "licher");check("licht", "licht");check("lichtbeeld", "lichtbeeld");check("lichtbruin", "lichtbruin");- check("lichtdoorlatende", "lichtdoorlat");+ check("lichtdoorlatende", "lichtdoorlaat");check("lichte", "licht");check("lichten", "licht");- check("lichtende", "lichtend");- check("lichtenvoorde", "lichtenvoord");+ check("lichtende", "licht");+ check("lichtenvoorde", "lichtenvoor");check("lichter", "lichter");check("lichtere", "lichter");check("lichters", "lichter");- check("lichtgevoeligheid", "lichtgevoel");- check("lichtgewicht", "lichtgewicht");+ check("lichtgevoeligheid", "lichtvoel");+ check("lichtgewicht", "lichtwicht");check("lichtgrijs", "lichtgrijs");- check("lichthoeveelheid", "lichthoevel");- check("lichtintensiteit", "lichtintensiteit");- check("lichtje", "lichtj");- check("lichtjes", "lichtjes");+ check("lichthoeveelheid", "lichthoeveel");+ check("lichtintensiteit", "lichtintens");+ check("lichtje", "licht");+ check("lichtjes", "licht");check("lichtkranten", "lichtkrant");- check("lichtkring", "lichtkring");- check("lichtkringen", "lichtkring");- check("lichtregelsystemen", "lichtregelsystem");- check("lichtste", "lichtst");- check("lichtstromende", "lichtstrom");+ check("lichtkring", "lichtkr");+ check("lichtkringen", "lichtkr");+ check("lichtregelsystemen", "lichtrelsysteem");+ check("lichtste", "licht");+ check("lichtstromende", "lichtstroom");check("lichtte", "licht");check("lichtten", "licht");- check("lichttoetreding", "lichttoetred");- check("lichtverontreinigde", "lichtverontreinigd");- check("lichtzinnige", "lichtzinn");+ check("lichttoetreding", "lichttoetreed");+ check("lichtverontreinigde", "lichtverontrein");+ check("lichtzinnige", "lichtzin");check("lid", "lid");check("lidia", "lidia");check("lidmaatschap", "lidmaatschap");- check("lidstaten", "lidstat");- check("lidvereniging", "lidveren");- check("opgingen", "opging");- check("opglanzing", "opglanz");- check("opglanzingen", "opglanz");+ check("lidstaten", "lidstaat");+ check("lidvereniging", "lidvereen");+ check("opgingen", "opg");+ check("opglanzing", "opglans");+ check("opglanzingen", "opglans");check("opglimlachten", "opglimlacht");check("opglimpen", "opglimp");check("opglimpende", "opglimp");check("opglimping", "opglimp");check("opglimpingen", "opglimp");- check("opgraven", "opgrav");- check("opgrijnzen", "opgrijnz");- check("opgrijzende", "opgrijz");+ check("opgraven", "opgraaf");+ check("opgrijnzen", "opgrijns");+ check("opgrijzende", "opgrijs");check("opgroeien", "opgroei");- check("opgroeiende", "opgroei");- check("opgroeiplaats", "opgroeiplat");- check("ophaal", "ophal");+ check("opgroeiende", "opgroeiend");+ check("opgroeiplaats", "opgroeiplaats");+ check("ophaal", "ophaal");check("ophaaldienst", "ophaaldienst");check("ophaalkosten", "ophaalkost");- check("ophaalsystemen", "ophaalsystem");+ check("ophaalsystemen", "ophaalsysteem");check("ophaalt", "ophaalt");check("ophaaltruck", "ophaaltruck");- check("ophalen", "ophal");- check("ophalend", "ophal");+ check("ophalen", "ophaal");+ check("ophalend", "ophaal");check("ophalers", "ophaler");check("ophef", "ophef");- check("opheldering", "ophelder");- check("ophemelde", "ophemeld");- check("ophemelen", "ophemel");- check("opheusden", "opheusd");+ check("opheldering", "opheldeer");+ check("ophemelde", "ophemel");+ check("ophemelen", "ophemeel");+ check("opheusden", "opheus");check("ophief", "ophief");check("ophield", "ophield");- check("ophieven", "ophiev");+ check("ophieven", "ophief");check("ophoepelt", "ophoepelt");- check("ophoog", "ophog");+ check("ophoog", "ophoog");check("ophoogzand", "ophoogzand");- check("ophopen", "ophop");- check("ophoping", "ophop");+ check("ophopen", "ophoop");+ check("ophoping", "ophoop");check("ophouden", "ophoud");}public void testSnowballCorrectness() throws Exception {Analyzer a = new DutchAnalyzer();- checkOneTerm(a, "opheffen", "opheff");- checkOneTerm(a, "opheffende", "opheff");- checkOneTerm(a, "opheffing", "opheff");+ checkOneTerm(a, "opheffen", "ophef");+ checkOneTerm(a, "opheffende", "ophef");+ checkOneTerm(a, "opheffing", "ophef");a.close();}public void testReusableTokenStream() throws Exception {Analyzer a = new DutchAnalyzer();checkOneTerm(a, "lichaamsziek", "lichaamsziek");- checkOneTerm(a, "lichamelijk", "licham");- checkOneTerm(a, "lichamelijke", "licham");- checkOneTerm(a, "lichamelijkheden", "licham");+ checkOneTerm(a, "lichamelijk", "lichamelijk");+ checkOneTerm(a, "lichamelijke", "lichamelijk");+ checkOneTerm(a, "lichamelijkheden", "lichamelijk");a.close();}@@ -130,11 +130,11 @@ public class TestDutchAnalyzer extends BaseTokenStreamTestCase {CharArraySet set = new CharArraySet(1, true);set.add("lichamelijk");DutchAnalyzer a = new DutchAnalyzer(CharArraySet.EMPTY_SET, set);- assertAnalyzesTo(a, "lichamelijk lichamelijke", new String[] {"lichamelijk", "licham"});+ assertAnalyzesTo(a, "lichamelijk lichamelijke", new String[] {"lichamelijk", "lichamelijk"});a.close();a = new DutchAnalyzer(CharArraySet.EMPTY_SET, set);- assertAnalyzesTo(a, "lichamelijk lichamelijke", new String[] {"lichamelijk", "licham"});+ assertAnalyzesTo(a, "lichamelijk lichamelijke", new String[] {"lichamelijk", "lichamelijk"});a.close();}diff --git a/lucene/analysis/common/src/test/org/apache/lucene/analysis/snowball/languages.txt b/lucene/analysis/common/src/test/org/apache/lucene/analysis/snowball/languages.txtindex 02fc7e7a90f..dbc157a089c 100644--- a/lucene/analysis/common/src/test/org/apache/lucene/analysis/snowball/languages.txt+++ b/lucene/analysis/common/src/test/org/apache/lucene/analysis/snowball/languages.txt@@ -3,8 +3,10 @@ ArmenianBasqueCatalanDanish+Dutch_porterDutchEnglish+EsperantoEstonianFinnishFrench@@ -18,6 +20,7 @@ ItalianLithuanianNepaliNorwegian+PolishPorterPortugueseRomaniandiff --git a/lucene/analysis/stempel/src/java/org/apache/lucene/analysis/pl/PolishSnowballAnalyzer.java b/lucene/analysis/stempel/src/java/org/apache/lucene/analysis/pl/PolishSnowballAnalyzer.javanew file mode 100644index 00000000000..fce0afb2f97--- /dev/null+++ b/lucene/analysis/stempel/src/java/org/apache/lucene/analysis/pl/PolishSnowballAnalyzer.java@@ -0,0 +1,97 @@+/*+ * Licensed to the Apache Software Foundation (ASF) under one or more+ * contributor license agreements. See the NOTICE file distributed with+ * this work for additional information regarding copyright ownership.+ * The ASF licenses this file to You under the Apache License, Version 2.0+ * (the "License"); you may not use this file except in compliance with+ * the License. You may obtain a copy of the License at+ *+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software+ * distributed under the License is distributed on an "AS IS" BASIS,+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ * See the License for the specific language governing permissions and+ * limitations under the License.+ */+package org.apache.lucene.analysis.pl;++import java.io.Reader;+import org.apache.lucene.analysis.Analyzer;+import org.apache.lucene.analysis.Analyzer.TokenStreamComponents;+import org.apache.lucene.analysis.CharArraySet;+import org.apache.lucene.analysis.LowerCaseFilter;+import org.apache.lucene.analysis.StopFilter;+import org.apache.lucene.analysis.StopwordAnalyzerBase;+import org.apache.lucene.analysis.TokenStream;+import org.apache.lucene.analysis.Tokenizer;+import org.apache.lucene.analysis.miscellaneous.SetKeywordMarkerFilter;+import org.apache.lucene.analysis.snowball.SnowballFilter;+import org.apache.lucene.analysis.standard.StandardTokenizer;+import org.tartarus.snowball.ext.PolishStemmer;++/** An {@link Analyzer} for the Polish language based on the built-in snowball stemmer. */+public final class PolishSnowballAnalyzer extends StopwordAnalyzerBase {+ /** File containing default Polish stopwords. */+ public static final String DEFAULT_STOPWORD_FILE = "stopwords.txt";++ private final CharArraySet stemExclusionSet;++ /**+ * Returns an unmodifiable instance of the default stop words set.+ *+ * @return default stop words set.+ */+ public static CharArraySet getDefaultStopSet() {+ return PolishAnalyzer.getDefaultStopSet();+ }++ /** Builds an analyzer with the default stop words: {@link #DEFAULT_STOPWORD_FILE}. */+ public PolishSnowballAnalyzer() {+ this(getDefaultStopSet());+ }++ /**+ * Builds an analyzer with the given stop words.+ *+ * @param stopwords a stopword set+ */+ public PolishSnowballAnalyzer(CharArraySet stopwords) {+ this(stopwords, CharArraySet.EMPTY_SET);+ }++ /**+ * Builds an analyzer with the given stop words. If a non-empty stem exclusion set is provided+ * this analyzer will add a {@link SetKeywordMarkerFilter} before stemming.+ *+ * @param stopwords a stopword set+ * @param stemExclusionSet a set of terms not to be stemmed+ */+ public PolishSnowballAnalyzer(CharArraySet stopwords, CharArraySet stemExclusionSet) {+ super(stopwords);+ this.stemExclusionSet = CharArraySet.unmodifiableSet(CharArraySet.copy(stemExclusionSet));+ }++ /**+ * Creates a {@link TokenStreamComponents} which tokenizes all the text in the provided {@link+ * Reader}.+ *+ * @return A {@link TokenStreamComponents} built from an {@link StandardTokenizer} filtered with+ * {@link LowerCaseFilter}, {@link StopFilter} , {@link SetKeywordMarkerFilter} if a stem+ * exclusion set is provided and {@link PolishStemmer}.+ */+ @Override+ protected TokenStreamComponents createComponents(String fieldName) {+ final Tokenizer source = new StandardTokenizer();+ TokenStream result = new LowerCaseFilter(source);+ result = new StopFilter(result, stopwords);+ if (!stemExclusionSet.isEmpty()) result = new SetKeywordMarkerFilter(result, stemExclusionSet);+ result = new SnowballFilter(result, new PolishStemmer());+ return new TokenStreamComponents(source, result);+ }++ @Override+ protected TokenStream normalize(String fieldName, TokenStream in) {+ return new LowerCaseFilter(in);+ }+}diff --git a/lucene/analysis/stempel/src/test/org/apache/lucene/analysis/pl/TestPolishSnowballAnalyzer.java b/lucene/analysis/stempel/src/test/org/apache/lucene/analysis/pl/TestPolishSnowballAnalyzer.javanew file mode 100644index 00000000000..e682ff75439--- /dev/null+++ b/lucene/analysis/stempel/src/test/org/apache/lucene/analysis/pl/TestPolishSnowballAnalyzer.java@@ -0,0 +1,65 @@+/*+ * Licensed to the Apache Software Foundation (ASF) under one or more+ * contributor license agreements. See the NOTICE file distributed with+ * this work for additional information regarding copyright ownership.+ * The ASF licenses this file to You under the Apache License, Version 2.0+ * (the "License"); you may not use this file except in compliance with+ * the License. You may obtain a copy of the License at+ *+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software+ * distributed under the License is distributed on an "AS IS" BASIS,+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+ * See the License for the specific language governing permissions and+ * limitations under the License.+ */+package org.apache.lucene.analysis.pl;++import java.io.IOException;+import org.apache.lucene.analysis.Analyzer;+import org.apache.lucene.analysis.CharArraySet;+import org.apache.lucene.tests.analysis.BaseTokenStreamTestCase;++public class TestPolishSnowballAnalyzer extends BaseTokenStreamTestCase {+ /** This test fails with NPE when the stopwords file is missing in classpath */+ public void testResourcesAvailable() {+ new PolishSnowballAnalyzer().close();+ }++ /** test stopwords and stemming */+ public void testBasics() throws IOException {+ Analyzer a = new PolishSnowballAnalyzer();+ // stemming+ checkOneTerm(a, "studenta", "student");+ checkOneTerm(a, "studenci", "studenc");+ checkOneTerm(a, "studentowi", "student");+ checkOneTerm(a, "studentach", "student");+ checkOneTerm(a, "studencki", "studenck");+ checkOneTerm(a, "los", "los");+ checkOneTerm(a, "browary", "browar");+ checkOneTerm(a, "popychane", "popychan");+ checkOneTerm(a, "zapiekankami", "zapiekank");++ // stopword+ assertAnalyzesTo(a, "był", new String[] {});+ a.close();+ }++ /** test use of exclusion set */+ public void testExclude() throws IOException {+ CharArraySet exclusionSet = new CharArraySet(asSet("studenta"), false);+ Analyzer a =+ new PolishSnowballAnalyzer(PolishSnowballAnalyzer.getDefaultStopSet(), exclusionSet);+ checkOneTerm(a, "studenta", "studenta");+ checkOneTerm(a, "studenci", "studenc");+ a.close();+ }++ /** blast some random strings through the analyzer */+ public void testRandomStrings() throws Exception {+ Analyzer analyzer = new PolishSnowballAnalyzer();+ checkRandomData(random(), analyzer, 200 * RANDOM_MULTIPLIER);+ analyzer.close();+ }+}