[logaling-commit] logaling/logalimacs [master] loga-singularize: Treat irregular-nous as first priority if word matched it

Back to archive index

Yuta Yamada null+****@clear*****
Thu Sep 27 20:19:36 JST 2012


Yuta Yamada	2012-09-27 20:19:36 +0900 (Thu, 27 Sep 2012)

  New Revision: a2b3da3751902ffe2936104585fd208b224c5ae9
  https://github.com/logaling/logalimacs/commit/a2b3da3751902ffe2936104585fd208b224c5ae9

  Log:
    loga-singularize: Treat irregular-nous as first priority if word matched it

  Modified files:
    logalimacs.el

  Modified: logalimacs.el (+3 -1)
===================================================================
--- logalimacs.el    2012-09-27 20:12:53 +0900 (d21095c)
+++ logalimacs.el    2012-09-27 20:19:36 +0900 (879401c)
@@ -720,7 +720,9 @@ Otherwise passed character inside region."
 (defun loga-singularize (word)
   (if (and loga-use-singular-form
            (not (loga-irregular-word-p word)))
-      (loop for (regexp replace) in loga-singular-regexp
+      (loop with singlurar-regexp = (append loga-irregular-nouns
+                                            loga-singular-regexp)
+            for (regexp replace) in singlurar-regexp
             if (string-match regexp word)
             do (return (replace-regexp-in-string regexp replace word))
             finally return word)
-------------- next part --------------
An HTML attachment was scrubbed...
下载 



More information about the logaling-commit mailing list
Back to archive index