diff options
| author | Stefan Monnier | 2004-06-30 19:34:34 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2004-06-30 19:34:34 +0000 |
| commit | bd2cbd5656b006c796a798dc605f2959d890d100 (patch) | |
| tree | 301e77a858a998d16c9205eebca31e07d49f7b77 /src | |
| parent | 85b0dba0fbca6d9ea4ba473e8f6746cfbb451379 (diff) | |
| download | emacs-bd2cbd5656b006c796a798dc605f2959d890d100.tar.gz emacs-bd2cbd5656b006c796a798dc605f2959d890d100.zip | |
(match_limit, Fmatch_data, Fset_match_data): YAILOM.
Diffstat (limited to 'src')
| -rw-r--r-- | src/search.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/search.c b/src/search.c index bd187181ecf..169baf05d55 100644 --- a/src/search.c +++ b/src/search.c | |||
| @@ -1,5 +1,6 @@ | |||
| 1 | /* String search routines for GNU Emacs. | 1 | /* String search routines for GNU Emacs. |
| 2 | Copyright (C) 1985, 86,87,93,94,97,98, 1999 Free Software Foundation, Inc. | 2 | Copyright (C) 1985, 86,87,93,94,97,98, 1999, 2004 |
| 3 | Free Software Foundation, Inc. | ||
| 3 | 4 | ||
| 4 | This file is part of GNU Emacs. | 5 | This file is part of GNU Emacs. |
| 5 | 6 | ||
| @@ -2628,7 +2629,7 @@ match_limit (num, beginningp) | |||
| 2628 | CHECK_NUMBER (num); | 2629 | CHECK_NUMBER (num); |
| 2629 | n = XINT (num); | 2630 | n = XINT (num); |
| 2630 | if (n < 0) | 2631 | if (n < 0) |
| 2631 | args_out_of_range (num, 0); | 2632 | args_out_of_range (num, make_number (0)); |
| 2632 | if (search_regs.num_regs <= 0) | 2633 | if (search_regs.num_regs <= 0) |
| 2633 | error ("No match data, because no search succeeded"); | 2634 | error ("No match data, because no search succeeded"); |
| 2634 | if (n >= search_regs.num_regs | 2635 | if (n >= search_regs.num_regs |
| @@ -2728,10 +2729,9 @@ Return value is undefined if the last search failed. */) | |||
| 2728 | data[2 * i] = data [2 * i + 1] = Qnil; | 2729 | data[2 * i] = data [2 * i + 1] = Qnil; |
| 2729 | } | 2730 | } |
| 2730 | 2731 | ||
| 2731 | if (BUFFERP(last_thing_searched) | 2732 | if (BUFFERP (last_thing_searched) && !NILP (integers)) |
| 2732 | && ! NILP (integers)) | ||
| 2733 | { | 2733 | { |
| 2734 | XSETBUFFER(data[len], last_thing_searched); | 2734 | data[len] = last_thing_searched; |
| 2735 | len++; | 2735 | len++; |
| 2736 | } | 2736 | } |
| 2737 | 2737 | ||
| @@ -2811,9 +2811,9 @@ LIST should have been created by calling `match-data' previously. */) | |||
| 2811 | for (i = 0;; i++) | 2811 | for (i = 0;; i++) |
| 2812 | { | 2812 | { |
| 2813 | marker = Fcar (list); | 2813 | marker = Fcar (list); |
| 2814 | if (BUFFERP(marker)) | 2814 | if (BUFFERP (marker)) |
| 2815 | { | 2815 | { |
| 2816 | XSETBUFFER(last_thing_searched, marker); | 2816 | last_thing_searched = marker; |
| 2817 | break; | 2817 | break; |
| 2818 | } | 2818 | } |
| 2819 | if (i >= length) | 2819 | if (i >= length) |