소스 검색

safer equality test in org-babel-header-arg-expand

* lisp/ob.el (org-babel-header-arg-expand): In new
  buffers (char-before) may return nil so use equal rather than =.
Eric Schulte 13 년 전
부모
커밋
bc473299f1
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      lisp/ob.el

+ 1 - 1
lisp/ob.el

@@ -693,7 +693,7 @@ arguments and pop open the results in a preview buffer."
 ;; Add support for completing-read insertion of header arguments after ":"
 (defun org-babel-header-arg-expand ()
   "Call `org-babel-enter-header-arg-w-completion' in appropriate contexts."
-  (when (and (= (char-before) ?\:) (org-babel-where-is-src-block-head))
+  (when (and (equal (char-before) ?\:) (org-babel-where-is-src-block-head))
     (org-babel-enter-header-arg-w-completion (match-string 2))))
 
 (defun org-babel-enter-header-arg-w-completion (&optional lang)