mirror of
https://github.com/rfivet/uemacs.git
synced 2024-12-18 23:36:23 -05:00
uemacs: Make some magic variables private to search.c module.
Signed-off-by: Thiago Farina <tfransosi@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
d6e76cca7b
commit
bf3c3ac2bd
8
edef.h
8
edef.h
@ -115,14 +115,6 @@ extern char *patmatch;
|
|||||||
extern struct line *matchline;
|
extern struct line *matchline;
|
||||||
extern int matchoff;
|
extern int matchoff;
|
||||||
|
|
||||||
#if MAGIC
|
|
||||||
extern short int magical;
|
|
||||||
extern short int rmagical;
|
|
||||||
extern struct magic mcpat[NPAT]; /* The magic pattern. */
|
|
||||||
extern struct magic tapcm[NPAT]; /* The reversed magic patterni. */
|
|
||||||
extern struct magic_replacement rmcpat[NPAT]; /* The replacement magic array. */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern char *dname[]; /* Directive name table. */
|
extern char *dname[]; /* Directive name table. */
|
||||||
|
|
||||||
#if DEBUGM
|
#if DEBUGM
|
||||||
|
17
globals.c
17
globals.c
@ -119,21 +119,6 @@ char *patmatch = NULL;
|
|||||||
struct line *matchline = NULL;
|
struct line *matchline = NULL;
|
||||||
int matchoff = 0;
|
int matchoff = 0;
|
||||||
|
|
||||||
#if MAGIC
|
|
||||||
/*
|
|
||||||
* The variables magical and rmagical determine if there
|
|
||||||
* were actual metacharacters in the search and replace strings -
|
|
||||||
* if not, then we don't have to use the slower MAGIC mode
|
|
||||||
* search functions.
|
|
||||||
*/
|
|
||||||
short int magical = FALSE;
|
|
||||||
short int rmagical = FALSE;
|
|
||||||
struct magic mcpat[NPAT]; /* the magic pattern */
|
|
||||||
struct magic tapcm[NPAT]; /* the reversed magic pattern */
|
|
||||||
struct magic_replacement rmcpat[NPAT]; /* the replacement magic array */
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* directive name table:
|
/* directive name table:
|
||||||
This holds the names of all the directives.... */
|
This holds the names of all the directives.... */
|
||||||
|
|
||||||
@ -148,5 +133,3 @@ char *dname[] = {
|
|||||||
/* vars needed for macro debugging output */
|
/* vars needed for macro debugging output */
|
||||||
char outline[NSTRING]; /* global string to hold debug line text */
|
char outline[NSTRING]; /* global string to hold debug line text */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
14
search.c
14
search.c
@ -64,6 +64,20 @@
|
|||||||
#include "efunc.h"
|
#include "efunc.h"
|
||||||
#include "line.h"
|
#include "line.h"
|
||||||
|
|
||||||
|
#if defined(MAGIC)
|
||||||
|
/*
|
||||||
|
* The variables magical and rmagical determine if there
|
||||||
|
* were actual metacharacters in the search and replace strings -
|
||||||
|
* if not, then we don't have to use the slower MAGIC mode
|
||||||
|
* search functions.
|
||||||
|
*/
|
||||||
|
static short int magical;
|
||||||
|
static short int rmagical;
|
||||||
|
static struct magic mcpat[NPAT]; /* The magic pattern. */
|
||||||
|
static struct magic tapcm[NPAT]; /* The reversed magic patterni. */
|
||||||
|
static struct magic_replacement rmcpat[NPAT]; /* The replacement magic array. */
|
||||||
|
#endif
|
||||||
|
|
||||||
static int amatch(struct magic *mcptr, int direct, struct line **pcwline, int *pcwoff);
|
static int amatch(struct magic *mcptr, int direct, struct line **pcwline, int *pcwoff);
|
||||||
static int readpattern(char *prompt, char *apat, int srch);
|
static int readpattern(char *prompt, char *apat, int srch);
|
||||||
static int replaces(int kind, int f, int n);
|
static int replaces(int kind, int f, int n);
|
||||||
|
Loading…
Reference in New Issue
Block a user