[ < ] | [ > ] | [ << ] | [Plus haut] | [ >> ] | [Top] | [Table des matières] | [Index] | [ ? ] |
Emacs keeps track of the start and end positions of the segments of text found during a search; this is called the match data. Thanks to the match data, you can search for a complex pattern, such as a date in a mail message, and then extract parts of the match under control of the pattern.
Because the match data normally describe the most recent search only, you must be careful not to do another search inadvertently between the search you wish to refer back to and the use of the match data. If you can't avoid another intervening search, you must save and restore the match data around it, to prevent it from being overwritten.
34.6.1 Replacing the Text that Matched | Replacing a substring that was matched. | |
34.6.2 Simple Match Data Access | Accessing single items of match data, such as where a particular subexpression started. | |
34.6.3 Accessing the Entire Match Data | Accessing the entire match data at once, as a list. | |
34.6.4 Saving and Restoring the Match Data | Saving and restoring the match data. |
Ce document a été généré par Eric Reinbold le 13 Octobre 2007 en utilisant texi2html 1.78.