Improve m4 compatibility with GNU m4 extension ** (exponent)
Submitted by: Marc Espie (espie@OpenBSD.org) Approved by: des@ (mentor)
This commit is contained in:
parent
bf9abaa954
commit
fb3f3d7caf
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=234310
@ -269,10 +269,11 @@ expand_builtin(const char *argv[], int argc, int td)
|
||||
case INCLTYPE:
|
||||
if (argc > 2)
|
||||
if (!doincl(argv[2])) {
|
||||
if (mimic_gnu)
|
||||
if (mimic_gnu) {
|
||||
warn("%s at line %lu: include(%s)",
|
||||
CURRENT_NAME, CURRENT_LINE, argv[2]);
|
||||
else
|
||||
exit_code = 1;
|
||||
} else
|
||||
err(1, "%s at line %lu: include(%s)",
|
||||
CURRENT_NAME, CURRENT_LINE, argv[2]);
|
||||
}
|
||||
|
@ -87,6 +87,7 @@ extern ndptr macro_getbuiltin(const char *);
|
||||
/* main.c */
|
||||
extern void outputstr(const char *);
|
||||
extern void do_emit_synchline(void);
|
||||
extern int exit_code;
|
||||
#define emit_synchline() do { if (synch_lines) do_emit_synchline(); } while(0)
|
||||
|
||||
/* misc.c */
|
||||
|
@ -164,6 +164,8 @@ static void enlarge_stack(void);
|
||||
|
||||
int main(int, char *[]);
|
||||
|
||||
int exit_code = 0;
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
@ -282,7 +284,7 @@ main(int argc, char *argv[])
|
||||
(void) fclose(outfile[0]);
|
||||
}
|
||||
|
||||
return 0;
|
||||
return exit_code;
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user