diff options
| author | Miles Bader | 2000-08-16 02:34:28 +0000 |
|---|---|---|
| committer | Miles Bader | 2000-08-16 02:34:28 +0000 |
| commit | 04231ab822f5ff597aac5c99b8277bbc36b24813 (patch) | |
| tree | 506d595585275efffb6bebcd3e82c64497290674 /lisp/progmodes/sql.el | |
| parent | 4d5d6aabc3baaa3ecfd6982d6e19d2797e020dd4 (diff) | |
| download | emacs-04231ab822f5ff597aac5c99b8277bbc36b24813.tar.gz emacs-04231ab822f5ff597aac5c99b8277bbc36b24813.zip | |
Add compatibility definition of comint-line-beginning-position.
Diffstat (limited to 'lisp/progmodes/sql.el')
| -rw-r--r-- | lisp/progmodes/sql.el | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 8cfd0278f3c..2a50422abf6 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el | |||
| @@ -654,6 +654,17 @@ used for the default `font-lock-defaults' value in `sql-mode'. This | |||
| 654 | can be changed by some entry functions to provide more hilighting.") | 654 | can be changed by some entry functions to provide more hilighting.") |
| 655 | 655 | ||
| 656 | 656 | ||
| 657 | ;;; Compatibility functions | ||
| 658 | |||
| 659 | (if (not (fboundp 'comint-line-beginning-position)) | ||
| 660 | ;; comint-line-beginning-position is defined in Emacs 21 | ||
| 661 | (defun comint-line-beginning-position () | ||
| 662 | "Returns the buffer position of the beginning of the line, after any prompt. | ||
| 663 | The prompt is assumed to be any text at the beginning of the line matching | ||
| 664 | the regular expression `comint-prompt-regexp', a buffer local variable." | ||
| 665 | (save-excursion (comint-bol nil) (point)))) | ||
| 666 | |||
| 667 | |||
| 657 | 668 | ||
| 658 | ;;; Small functions | 669 | ;;; Small functions |
| 659 | 670 | ||