Python mode - `C-c |' feature suggestion
pinard at iro.umontreal.ca
Tue Feb 22 16:55:34 EST 2000
Alex <alex at somewhere.round.here> writes:
I sometimes wonder, yes. (Even if I don't use XEmacs much myself :-).
> > The `-no-properties' functions are less portable.
> It just popped up when I hit complete.
Just to be complete, it does happen that properties get in the way.
In some portable code, I use this:
;; Protect string comparisons from text properties if possible.
(symbol-function (if (fboundp 'buffer-substring-no-properties)
(if (fboundp 'match-string-no-properties)
(fset 'po-match-string (symbol-function 'match-string-no-properties))
(defun po-match-string (number)
"Return string of text matched by last search."
(po-buffer-substring (match-beginning number) (match-end number)))))
François Pinard http://www.iro.umontreal.ca/~pinard
More information about the Python-list