Browse Source

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

Eric Schulte 15 years ago
parent
commit
6151c88f10
1 changed files with 1 additions and 2 deletions
  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:"