Function: org-table-formula-make-cmp-string
org-table-formula-make-cmp-string is a byte-compiled function defined
in org-table.el.gz.
Signature
(org-table-formula-make-cmp-string A)
Source Code
;; Defined in /usr/src/emacs/lisp/org/org-table.el.gz
(defsubst org-table-formula-make-cmp-string (a)
(when (string-match "\\`\\$[<>]" a)
(let ((arrow (string-to-char (substring a 1))))
;; Fake a high number to make sure this is sorted at the end.
(setq a (org-table-formula-handle-first/last-rc a))
(setq a (format "$%d" (+ 10000
(if (= arrow ?<) -1000 0)
(string-to-number (substring a 1)))))))
(when (string-match
"^\\(@\\([0-9]+\\)\\)?\\(\\$?\\([0-9]+\\)\\)?\\(\\$?[a-zA-Z0-9]+\\)?"
a)
(concat
(if (match-end 2)
(format "@%05d" (string-to-number (match-string 2 a))) "")
(if (match-end 4)
(format "$%05d" (string-to-number (match-string 4 a))) "")
(if (match-end 5)
(concat "@@" (match-string 5 a))))))