add the "regexp" rcfile option back in at DB's suggestion, the
"casesensitive" and "backwards" rcfile options for consistency, documentation updates, and related cleanups git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2700 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
f774017801
commit
f3ecffd24d
12
ChangeLog
12
ChangeLog
|
@ -47,13 +47,12 @@ CVS code -
|
||||||
write_file(), write_marked(), die(), do_spell(), and
|
write_file(), write_marked(), die(), do_spell(), and
|
||||||
do_exit(). (DLR)
|
do_exit(). (DLR)
|
||||||
- Remove the -R/--regexp command line option and enable the
|
- Remove the -R/--regexp command line option and enable the
|
||||||
toggle at the search promptin tiny mode, as it already
|
toggle at the search prompt in tiny mode, as it already
|
||||||
allows the prepend and append toggles at the search prompt.
|
allows the prepend and append toggles at the search prompt.
|
||||||
For consistency, rename TOGGLE_REGEXP_KEY to NANO_REGEXP_KEY,
|
For consistency, rename TOGGLE_REGEXP_KEY to NANO_REGEXP_KEY,
|
||||||
and move it out of the toggles block to where NANO_PREPEND_KEY
|
and move it out of the toggles block to where NANO_PREPEND_KEY
|
||||||
and NANO_APPEND_KEY are. Changes to shortcut_init(), usage(),
|
and NANO_APPEND_KEY are. Changes to shortcut_init(), usage(),
|
||||||
main(), search_init(), nanorc.sample, nano.1, nanorc.5,
|
main(), search_init(), nano.1, nano.texi, etc. (DLR)
|
||||||
nano.texi, etc. (DLR)
|
|
||||||
- Various cleanups and improvements in chars.c. Remove some
|
- Various cleanups and improvements in chars.c. Remove some
|
||||||
unnecessary w?ctype wrappers; change the wctype wrappers to
|
unnecessary w?ctype wrappers; change the wctype wrappers to
|
||||||
take wint_t instead of wchar_t to match the functions they
|
take wint_t instead of wchar_t to match the functions they
|
||||||
|
@ -95,9 +94,14 @@ CVS code -
|
||||||
toggle_init(), usage(), do_tab(), main(), nanorc.sample,
|
toggle_init(), usage(), do_tab(), main(), nanorc.sample,
|
||||||
nano.1, nanorc.5, and nano.texi. (DLR, suggested by many
|
nano.1, nanorc.5, and nano.texi. (DLR, suggested by many
|
||||||
people)
|
people)
|
||||||
|
- Change the REVERSE_SEARCH flag to the BACKWARDS_SEARCH flag.
|
||||||
|
(DLR)
|
||||||
- Change the SMOOTHSCROLL flag to the SMOOTH_SCROLL flag. (DLR)
|
- Change the SMOOTHSCROLL flag to the SMOOTH_SCROLL flag. (DLR)
|
||||||
- Change the NO_UTF8 flag to the USE_UTF8 flag, and reverse its
|
- Change the NO_UTF8 flag to the USE_UTF8 flag, and reverse its
|
||||||
meaning. (DLR)
|
meaning. (DLR)
|
||||||
|
- Add rcfile options "casesensitive" and "backwards", to do
|
||||||
|
case sensitive and backwards searches by default. Changes to
|
||||||
|
nanorc.sample and nanorc.5. (DLR)
|
||||||
- chars.c:
|
- chars.c:
|
||||||
make_mbstring()
|
make_mbstring()
|
||||||
- Change erroneous ENABLE_EXTRA #ifdef to NANO_EXTRA to fix a
|
- Change erroneous ENABLE_EXTRA #ifdef to NANO_EXTRA to fix a
|
||||||
|
@ -157,6 +161,8 @@ CVS code -
|
||||||
- Allow the mark to be used in view mode, as Pico does. (DLR)
|
- Allow the mark to be used in view mode, as Pico does. (DLR)
|
||||||
- Clarify the description of ^X when --enable-multibuffer is
|
- Clarify the description of ^X when --enable-multibuffer is
|
||||||
used. (DLR)
|
used. (DLR)
|
||||||
|
- Change the description of the Meta-B toggle at the search
|
||||||
|
prompt from "Direction" to "Backwards", for consistency. (DLR)
|
||||||
thanks_for_all_the_fish()
|
thanks_for_all_the_fish()
|
||||||
- Remove free_toggles() and move its code here verbatim, as it's
|
- Remove free_toggles() and move its code here verbatim, as it's
|
||||||
only called here anyway. (David Benbennick)
|
only called here anyway. (David Benbennick)
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
.\" Public License for copying conditions. There is NO warranty.
|
.\" Public License for copying conditions. There is NO warranty.
|
||||||
.\"
|
.\"
|
||||||
.\" $Id$
|
.\" $Id$
|
||||||
.TH NANORC 5 "version 1.3.8" "June 15, 2005"
|
.TH NANORC 5 "version 1.3.8" "June 16, 2005"
|
||||||
.\" Please adjust this date whenever revising the manpage.
|
.\" Please adjust this date whenever revising the manpage.
|
||||||
.\"
|
.\"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
|
@ -51,11 +51,18 @@ Create backup files in
|
||||||
\fBset backupdir "\fIdirectory\fP"\fP
|
\fBset backupdir "\fIdirectory\fP"\fP
|
||||||
Set the directory where \fBnano\fP puts unique backup files if file
|
Set the directory where \fBnano\fP puts unique backup files if file
|
||||||
backups are enabled.
|
backups are enabled.
|
||||||
|
.TP
|
||||||
|
\fBset/unset backwards\fP
|
||||||
|
Do backwards searches by default.
|
||||||
|
.TP
|
||||||
\fBset brackets "\fIstring\fP"\fP
|
\fBset brackets "\fIstring\fP"\fP
|
||||||
Set the characters treated as closing brackets. They cannot contain
|
Set the characters treated as closing brackets. They cannot contain
|
||||||
tabs or spaces. Only closing punctuation, optionally followed by
|
tabs or spaces. Only closing punctuation, optionally followed by
|
||||||
closing brackets, can end sentences.
|
closing brackets, can end sentences.
|
||||||
.TP
|
.TP
|
||||||
|
\fBset/unset casesensitive\fP
|
||||||
|
Do case sensitive searches by default.
|
||||||
|
.TP
|
||||||
\fBset/unset const\fP
|
\fBset/unset const\fP
|
||||||
Constantly display the cursor position in the status bar.
|
Constantly display the cursor position in the status bar.
|
||||||
.TP
|
.TP
|
||||||
|
@ -122,6 +129,9 @@ Interpret the Delete key differently so that both Backspace and Delete
|
||||||
work properly. You should only need to use this option if Backspace
|
work properly. You should only need to use this option if Backspace
|
||||||
acts like Delete on your system.
|
acts like Delete on your system.
|
||||||
.TP
|
.TP
|
||||||
|
\fBset/unset regexp\fP
|
||||||
|
Do regular expression searches by default.
|
||||||
|
.TP
|
||||||
\fBset/unset smarthome\fP
|
\fBset/unset smarthome\fP
|
||||||
Make the Home key smarter. When Home is pressed anywhere but at the
|
Make the Home key smarter. When Home is pressed anywhere but at the
|
||||||
very beginning of non-whitespace characters on a line, the cursor will
|
very beginning of non-whitespace characters on a line, the cursor will
|
||||||
|
|
|
@ -17,12 +17,18 @@
|
||||||
## The directory to put unique backup files in.
|
## The directory to put unique backup files in.
|
||||||
# set backupdir ""
|
# set backupdir ""
|
||||||
|
|
||||||
|
## Do backwards searches by default.
|
||||||
|
# set backwards
|
||||||
|
|
||||||
## The characters treated as closing brackets. They cannot contain tabs
|
## The characters treated as closing brackets. They cannot contain tabs
|
||||||
## or spaces. Only closing punctuation, optionally followed by closing
|
## or spaces. Only closing punctuation, optionally followed by closing
|
||||||
## brackets, can end sentences.
|
## brackets, can end sentences.
|
||||||
##
|
##
|
||||||
# set brackets "'")}]>"
|
# set brackets "'")}]>"
|
||||||
|
|
||||||
|
## Do case sensitive searches by default.
|
||||||
|
# set casesensitive
|
||||||
|
|
||||||
## Constantly display the cursor position in the status bar.
|
## Constantly display the cursor position in the status bar.
|
||||||
# set const
|
# set const
|
||||||
|
|
||||||
|
@ -91,6 +97,9 @@
|
||||||
## Fix Backspace/Delete confusion problem.
|
## Fix Backspace/Delete confusion problem.
|
||||||
# set rebinddelete
|
# set rebinddelete
|
||||||
|
|
||||||
|
## Do extended regular expression searches by default.
|
||||||
|
# set regexp
|
||||||
|
|
||||||
## Make the Home key smarter. When Home is pressed anywhere but at the
|
## Make the Home key smarter. When Home is pressed anywhere but at the
|
||||||
## very beginning of non-whitespace characters on a line, the cursor
|
## very beginning of non-whitespace characters on a line, the cursor
|
||||||
## will jump to that beginning (either forwards or backwards). If the
|
## will jump to that beginning (either forwards or backwards). If the
|
||||||
|
|
|
@ -253,7 +253,7 @@ void shortcut_init(bool unjustify)
|
||||||
#endif
|
#endif
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
const char *case_sens_msg = N_("Case Sens");
|
const char *case_sens_msg = N_("Case Sens");
|
||||||
const char *direction_msg = N_("Direction");
|
const char *backwards_msg = N_("Backwards");
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_REGEX_H
|
#ifdef HAVE_REGEX_H
|
||||||
const char *regexp_msg = N_("Regexp");
|
const char *regexp_msg = N_("Regexp");
|
||||||
|
@ -679,7 +679,7 @@ void shortcut_init(bool unjustify)
|
||||||
NANO_NO_KEY, VIEW, NULL);
|
NANO_NO_KEY, VIEW, NULL);
|
||||||
|
|
||||||
/* Translators: try to keep this string under 10 characters long */
|
/* Translators: try to keep this string under 10 characters long */
|
||||||
sc_init_one(&whereis_list, NANO_NO_KEY, direction_msg,
|
sc_init_one(&whereis_list, NANO_NO_KEY, backwards_msg,
|
||||||
IFHELP(nano_reverse_msg, TOGGLE_BACKWARDS_KEY), NANO_NO_KEY,
|
IFHELP(nano_reverse_msg, TOGGLE_BACKWARDS_KEY), NANO_NO_KEY,
|
||||||
NANO_NO_KEY, VIEW, NULL);
|
NANO_NO_KEY, VIEW, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
@ -748,7 +748,7 @@ void shortcut_init(bool unjustify)
|
||||||
IFHELP(nano_case_msg, TOGGLE_CASE_KEY), NANO_NO_KEY,
|
IFHELP(nano_case_msg, TOGGLE_CASE_KEY), NANO_NO_KEY,
|
||||||
NANO_NO_KEY, VIEW, NULL);
|
NANO_NO_KEY, VIEW, NULL);
|
||||||
|
|
||||||
sc_init_one(&replace_list, NANO_NO_KEY, direction_msg,
|
sc_init_one(&replace_list, NANO_NO_KEY, backwards_msg,
|
||||||
IFHELP(nano_reverse_msg, TOGGLE_BACKWARDS_KEY), NANO_NO_KEY,
|
IFHELP(nano_reverse_msg, TOGGLE_BACKWARDS_KEY), NANO_NO_KEY,
|
||||||
NANO_NO_KEY, VIEW, NULL);
|
NANO_NO_KEY, VIEW, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1955,7 +1955,7 @@ bool do_int_spell_fix(const char *word)
|
||||||
/* The return value. */
|
/* The return value. */
|
||||||
bool case_sens_set = ISSET(CASE_SENSITIVE);
|
bool case_sens_set = ISSET(CASE_SENSITIVE);
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
bool reverse_search_set = ISSET(REVERSE_SEARCH);
|
bool backwards_search_set = ISSET(BACKWARDS_SEARCH);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_REGEX_H
|
#ifdef HAVE_REGEX_H
|
||||||
bool regexp_set = ISSET(USE_REGEXP);
|
bool regexp_set = ISSET(USE_REGEXP);
|
||||||
|
@ -1976,7 +1976,7 @@ bool do_int_spell_fix(const char *word)
|
||||||
|
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
/* Make sure spell-check goes forward only. */
|
/* Make sure spell-check goes forward only. */
|
||||||
UNSET(REVERSE_SEARCH);
|
UNSET(BACKWARDS_SEARCH);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_REGEX_H
|
#ifdef HAVE_REGEX_H
|
||||||
/* Make sure spell-check doesn't use regular expressions. */
|
/* Make sure spell-check doesn't use regular expressions. */
|
||||||
|
@ -2091,8 +2091,8 @@ bool do_int_spell_fix(const char *word)
|
||||||
|
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
/* Restore search/replace direction. */
|
/* Restore search/replace direction. */
|
||||||
if (reverse_search_set)
|
if (backwards_search_set)
|
||||||
SET(REVERSE_SEARCH);
|
SET(BACKWARDS_SEARCH);
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_REGEX_H
|
#ifdef HAVE_REGEX_H
|
||||||
/* Restore regular expression usage setting. */
|
/* Restore regular expression usage setting. */
|
||||||
|
|
|
@ -288,7 +288,7 @@ typedef struct syntaxtype {
|
||||||
#define USE_REGEXP (1<<11)
|
#define USE_REGEXP (1<<11)
|
||||||
#define TEMP_FILE (1<<12)
|
#define TEMP_FILE (1<<12)
|
||||||
#define CUT_TO_END (1<<13)
|
#define CUT_TO_END (1<<13)
|
||||||
#define REVERSE_SEARCH (1<<14)
|
#define BACKWARDS_SEARCH (1<<14)
|
||||||
#define MULTIBUFFER (1<<15)
|
#define MULTIBUFFER (1<<15)
|
||||||
#define SMOOTH_SCROLL (1<<16)
|
#define SMOOTH_SCROLL (1<<16)
|
||||||
#define DISABLE_CURPOS (1<<17) /* Damn, we still need it. */
|
#define DISABLE_CURPOS (1<<17) /* Damn, we still need it. */
|
||||||
|
|
|
@ -41,9 +41,13 @@ const static rcoption rcopts[] = {
|
||||||
{"autoindent", AUTOINDENT},
|
{"autoindent", AUTOINDENT},
|
||||||
{"backup", BACKUP_FILE},
|
{"backup", BACKUP_FILE},
|
||||||
{"backupdir", 0},
|
{"backupdir", 0},
|
||||||
|
{"backwards", BACKWARDS_SEARCH},
|
||||||
#endif
|
#endif
|
||||||
#ifndef DISABLE_JUSTIFY
|
#ifndef DISABLE_JUSTIFY
|
||||||
{"brackets", 0},
|
{"brackets", 0},
|
||||||
|
#endif
|
||||||
|
#ifndef NANO_SMALL
|
||||||
|
{"casesensitive", CASE_SENSITIVE},
|
||||||
#endif
|
#endif
|
||||||
{"const", CONSTUPDATE},
|
{"const", CONSTUPDATE},
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
|
@ -79,6 +83,9 @@ const static rcoption rcopts[] = {
|
||||||
{"quotestr", 0},
|
{"quotestr", 0},
|
||||||
#endif
|
#endif
|
||||||
{"rebinddelete", REBIND_DELETE},
|
{"rebinddelete", REBIND_DELETE},
|
||||||
|
#ifdef HAVE_REGEX_H
|
||||||
|
{"regexp", USE_REGEXP},
|
||||||
|
#endif
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
{"smarthome", SMART_HOME},
|
{"smarthome", SMART_HOME},
|
||||||
{"smooth", SMOOTH_SCROLL},
|
{"smooth", SMOOTH_SCROLL},
|
||||||
|
|
22
src/search.c
22
src/search.c
|
@ -186,7 +186,7 @@ int search_init(bool replacing, bool use_answer)
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
/* This string is just a modifier for the search prompt; no
|
/* This string is just a modifier for the search prompt; no
|
||||||
* grammar is implied. */
|
* grammar is implied. */
|
||||||
ISSET(REVERSE_SEARCH) ? _(" [Backwards]") :
|
ISSET(BACKWARDS_SEARCH) ? _(" [Backwards]") :
|
||||||
#endif
|
#endif
|
||||||
"",
|
"",
|
||||||
|
|
||||||
|
@ -235,7 +235,7 @@ int search_init(bool replacing, bool use_answer)
|
||||||
backupstring = mallocstrcpy(backupstring, answer);
|
backupstring = mallocstrcpy(backupstring, answer);
|
||||||
return 1;
|
return 1;
|
||||||
case TOGGLE_BACKWARDS_KEY:
|
case TOGGLE_BACKWARDS_KEY:
|
||||||
TOGGLE(REVERSE_SEARCH);
|
TOGGLE(BACKWARDS_SEARCH);
|
||||||
backupstring = mallocstrcpy(backupstring, answer);
|
backupstring = mallocstrcpy(backupstring, answer);
|
||||||
return 1;
|
return 1;
|
||||||
#endif
|
#endif
|
||||||
|
@ -311,7 +311,7 @@ bool findnextstr(bool can_display_wrap, bool wholeword, bool
|
||||||
* previous or next line. */
|
* previous or next line. */
|
||||||
rev_start =
|
rev_start =
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
ISSET(REVERSE_SEARCH) ? fileptr->data + (current_x - 1) :
|
ISSET(BACKWARDS_SEARCH) ? fileptr->data + (current_x - 1) :
|
||||||
#endif
|
#endif
|
||||||
fileptr->data + (current_x + 1);
|
fileptr->data + (current_x + 1);
|
||||||
|
|
||||||
|
@ -360,7 +360,7 @@ bool findnextstr(bool can_display_wrap, bool wholeword, bool
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (ISSET(REVERSE_SEARCH)) {
|
if (ISSET(BACKWARDS_SEARCH)) {
|
||||||
fileptr = fileptr->prev;
|
fileptr = fileptr->prev;
|
||||||
current_y_find--;
|
current_y_find--;
|
||||||
} else {
|
} else {
|
||||||
|
@ -377,7 +377,7 @@ bool findnextstr(bool can_display_wrap, bool wholeword, bool
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (ISSET(REVERSE_SEARCH)) {
|
if (ISSET(BACKWARDS_SEARCH)) {
|
||||||
fileptr = filebot;
|
fileptr = filebot;
|
||||||
current_y_find = editwinrows - 1;
|
current_y_find = editwinrows - 1;
|
||||||
} else {
|
} else {
|
||||||
|
@ -398,7 +398,7 @@ bool findnextstr(bool can_display_wrap, bool wholeword, bool
|
||||||
|
|
||||||
rev_start = fileptr->data;
|
rev_start = fileptr->data;
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (ISSET(REVERSE_SEARCH))
|
if (ISSET(BACKWARDS_SEARCH))
|
||||||
rev_start += strlen(fileptr->data);
|
rev_start += strlen(fileptr->data);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
@ -409,8 +409,8 @@ bool findnextstr(bool can_display_wrap, bool wholeword, bool
|
||||||
/* Ensure we haven't wrapped around again! */
|
/* Ensure we haven't wrapped around again! */
|
||||||
if (search_last_line &&
|
if (search_last_line &&
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
((!ISSET(REVERSE_SEARCH) && current_x_find > beginx) ||
|
((!ISSET(BACKWARDS_SEARCH) && current_x_find > beginx) ||
|
||||||
(ISSET(REVERSE_SEARCH) && current_x_find < beginx))
|
(ISSET(BACKWARDS_SEARCH) && current_x_find < beginx))
|
||||||
#else
|
#else
|
||||||
current_x_find > beginx
|
current_x_find > beginx
|
||||||
#endif
|
#endif
|
||||||
|
@ -825,7 +825,7 @@ ssize_t do_replace_loop(const char *needle, const filestruct
|
||||||
* text. Note that current_x might be set to (size_t)-1
|
* text. Note that current_x might be set to (size_t)-1
|
||||||
* here. */
|
* here. */
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (!ISSET(REVERSE_SEARCH))
|
if (!ISSET(BACKWARDS_SEARCH))
|
||||||
#endif
|
#endif
|
||||||
current_x += match_len + length_change - 1;
|
current_x += match_len + length_change - 1;
|
||||||
|
|
||||||
|
@ -1073,12 +1073,12 @@ void do_find_bracket(void)
|
||||||
/* On a left bracket. */
|
/* On a left bracket. */
|
||||||
regexp_pat[1] = wanted_ch;
|
regexp_pat[1] = wanted_ch;
|
||||||
regexp_pat[2] = ch_under_cursor;
|
regexp_pat[2] = ch_under_cursor;
|
||||||
UNSET(REVERSE_SEARCH);
|
UNSET(BACKWARDS_SEARCH);
|
||||||
} else {
|
} else {
|
||||||
/* On a right bracket. */
|
/* On a right bracket. */
|
||||||
regexp_pat[1] = ch_under_cursor;
|
regexp_pat[1] = ch_under_cursor;
|
||||||
regexp_pat[2] = wanted_ch;
|
regexp_pat[2] = wanted_ch;
|
||||||
SET(REVERSE_SEARCH);
|
SET(BACKWARDS_SEARCH);
|
||||||
}
|
}
|
||||||
|
|
||||||
regexp_init(regexp_pat);
|
regexp_init(regexp_pat);
|
||||||
|
|
|
@ -259,7 +259,7 @@ const char *strstrwrapper(const char *haystack, const char *needle,
|
||||||
#ifdef HAVE_REGEX_H
|
#ifdef HAVE_REGEX_H
|
||||||
if (ISSET(USE_REGEXP)) {
|
if (ISSET(USE_REGEXP)) {
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (ISSET(REVERSE_SEARCH)) {
|
if (ISSET(BACKWARDS_SEARCH)) {
|
||||||
if (regexec(&search_regexp, haystack, 1, regmatches, 0) == 0
|
if (regexec(&search_regexp, haystack, 1, regmatches, 0) == 0
|
||||||
&& haystack + regmatches[0].rm_so <= start) {
|
&& haystack + regmatches[0].rm_so <= start) {
|
||||||
const char *retval = haystack + regmatches[0].rm_so;
|
const char *retval = haystack + regmatches[0].rm_so;
|
||||||
|
@ -290,7 +290,7 @@ const char *strstrwrapper(const char *haystack, const char *needle,
|
||||||
#if !defined(NANO_SMALL) || !defined(DISABLE_SPELLER)
|
#if !defined(NANO_SMALL) || !defined(DISABLE_SPELLER)
|
||||||
if (ISSET(CASE_SENSITIVE)) {
|
if (ISSET(CASE_SENSITIVE)) {
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
if (ISSET(REVERSE_SEARCH))
|
if (ISSET(BACKWARDS_SEARCH))
|
||||||
return revstrstr(haystack, needle, start);
|
return revstrstr(haystack, needle, start);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
|
@ -298,7 +298,7 @@ const char *strstrwrapper(const char *haystack, const char *needle,
|
||||||
}
|
}
|
||||||
#endif /* !DISABLE_SPELLER || !NANO_SMALL */
|
#endif /* !DISABLE_SPELLER || !NANO_SMALL */
|
||||||
#ifndef NANO_SMALL
|
#ifndef NANO_SMALL
|
||||||
else if (ISSET(REVERSE_SEARCH))
|
else if (ISSET(BACKWARDS_SEARCH))
|
||||||
return mbrevstrcasestr(haystack, needle, start);
|
return mbrevstrcasestr(haystack, needle, start);
|
||||||
#endif
|
#endif
|
||||||
return mbstrcasestr(start, needle);
|
return mbstrcasestr(start, needle);
|
||||||
|
|
Loading…
Reference in New Issue