You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2021/01/26 08:37:54 UTC

[GitHub] [lucene-solr] dweiss commented on a change in pull request #2243: LUCENE-9698: Hunspell: reuse char[] when possible when stripping affix

dweiss commented on a change in pull request #2243:
URL: https://github.com/apache/lucene-solr/pull/2243#discussion_r564331661



##########
File path: lucene/analysis/common/src/java/org/apache/lucene/analysis/hunspell/Stemmer.java
##########
@@ -403,7 +408,12 @@ private CharsRef newStem(char[] buffer, int length, IntsRef forms, int formID) {
     return stems;
   }
 
-  private char[] stripAffix(char[] word, int length, int affixLen, int affix, boolean isPrefix) {
+  /**
+   * @return null if affix conditions isn't met; the same char[] if the affix has no strip data and

Review comment:
       I'd make it clearer that it's "the same *reference* to char[] if the affix....". I did wonder a bit why you're comparing array refs directly (above) for a while. Also, not sure "de-affixation" is an English word (although I'm not a native English speaker too); "[...] after affix stripping" would be more legible, maybe?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org