[logaling-commit] logaling/logalimacs [master] Fix mistaken calculation for loga-character-of-point function

Zurück zum Archiv-Index

Yuta Yamada null+****@clear*****
Tue Aug 28 21:03:40 JST 2012


Yuta Yamada	2012-08-28 21:03:40 +0900 (Tue, 28 Aug 2012)

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

  Log:
    Fix mistaken calculation for loga-character-of-point function

  Modified files:
    logalimacs.el

  Modified: logalimacs.el (+3 -2)
===================================================================
--- logalimacs.el    2012-08-28 21:02:48 +0900 (a0e7894)
+++ logalimacs.el    2012-08-28 21:03:40 +0900 (40857e3)
@@ -603,8 +603,9 @@ Because it escape character"
 
 (defun loga-character-of-point ()
   (lexical-let* ((line (thing-at-point 'line))
-                 (address (1- (- (point) (point-at-bol))))
-                 (character (char-to-string (aref line address))))
+                 (address (- (point) (point-at-bol)))
+                 (limit   (1- (- (point-at-eol) (point-at-bol))))
+                 (character (char-to-string (aref line (min address limit)))))
     character))
 
 ;;;###autoload
-------------- next part --------------
An HTML attachment was scrubbed...
Download 



More information about the logaling-commit mailing list
Zurück zum Archiv-Index