Преглед изворни кода

babel: replaced `line-number-at-pos' with `count-lines'

Eric Schulte пре 15 година
родитељ
комит
6151c88f10
1 измењених фајлова са 1 додато и 2 уклоњено
  1. 1 2
      contrib/babel/lisp/org-babel.el

+ 1 - 2
contrib/babel/lisp/org-babel.el

@@ -1026,8 +1026,7 @@ directory then expand relative links."
 (defun org-babel-examplize-region (beg end &optional results-switches)
   "Comment out region using the ': ' org example quote."
   (interactive "*r")
-  (let ((size (abs (- (line-number-at-pos end)
-		      (line-number-at-pos beg)))))
+  (let ((size (count-lines beg end)))
     (save-excursion
       (cond ((= size 0)
 	     (error (concat "This should be impossible:"