You are here

function step1c in Porter-Stemmer 6

Same name and namespace in other branches
  1. 5 porterstemmer.module \step1c()

Step 1c

Parameters

string $word Word to stem:

1 call to step1c()
stem in ./porterstemmer.module
Stems a word. Simple huh?

File

./porterstemmer.module, line 126

Code

function step1c($word) {
  $v = regex_vowel;
  if (substr($word, -1) == 'y' && preg_match("#{$v}+#", substr($word, 0, -1))) {
    replace($word, 'y', 'i');
  }
  return $word;
}