ソースを参照

Merge branch 'maint'

Nicolas Goaziou 7 年 前
コミット
b8d89496fd
1 ファイル変更5 行追加3 行削除
  1. 5 3
      lisp/org-table.el

+ 5 - 3
lisp/org-table.el

@@ -1663,13 +1663,15 @@ In particular, this does handle wide and invisible characters."
   (interactive)
   (unless (org-at-table-p) (user-error "Not at a table"))
   (let ((col (current-column))
-	(dline (org-table-current-dline)))
+	(dline (and (not (org-match-line org-table-hline-regexp))
+		    (org-table-current-dline))))
     (org-table-with-shrunk-columns
      (kill-region (point-at-bol) (min (1+ (point-at-eol)) (point-max)))
      (if (not (org-at-table-p)) (beginning-of-line 0))
      (org-move-to-column col)
-     (when (or (not org-table-fix-formulas-confirm)
-	       (funcall org-table-fix-formulas-confirm "Fix formulas? "))
+     (when (and dline
+		(or (not org-table-fix-formulas-confirm)
+		    (funcall org-table-fix-formulas-confirm "Fix formulas? ")))
        (org-table-fix-formulas
 	"@" (list (cons (number-to-string dline) "INVALID")) dline -1 dline)))))