original_string: public static function replaceLastOccurrence($search, $replace, $subject)
      {
          $pos = strrpos($subject, $search);
  
          if($pos !== false)
          {
              $subject = static::mb_substr_replace($subject, $replace, $pos, mb_strlen($search));
          }
  
          return $subject;
      }
code: public static function replaceLastOccurrence($search, $replace, $subject)
      {
          $pos = strrpos($subject, $search);
  
          if($pos !== false)
          {
              $subject = static::mb_substr_replace($subject, $replace, $pos, mb_strlen($search));
          }
  
          return $subject;
      }
code_tokens: public static function replaceLastOccurrence ( $ search , $ replace , $ subject ) { $ pos = strrpos ( $ subject , $ search ) ; if ( $ pos !== false ) { $ subject = static :: mb_substr_replace ( $ subject , $ replace , $ pos , mb_strlen ( $ search ) ) ; } return $ subject ; }
docstring: Utility method to replace only the last occurrence in a string
  
  @param string $search
  @param string $replace
  @param string $subject
  @return string
docstring_tokens: Utility method to replace only the last occurrence in a string