summaryrefslogtreecommitdiff
path: root/unsorted/ParserHelpers-cc.c
diff options
context:
space:
mode:
authorAsh Wolf <ninji@wuffs.org>2022-10-19 21:16:13 +0100
committerAsh Wolf <ninji@wuffs.org>2022-10-19 21:16:13 +0100
commitd1f153d34b023d81768f6087f67dbfff714bafc9 (patch)
treea694d470a60655d0cda15a70791fbdb90a2398cf /unsorted/ParserHelpers-cc.c
parent775b6861666af36d317fb577cf489e2c6377f878 (diff)
downloadMWCC-d1f153d34b023d81768f6087f67dbfff714bafc9.tar.gz
MWCC-d1f153d34b023d81768f6087f67dbfff714bafc9.zip
let's commit all this before my VM blows up and nukes my work
Diffstat (limited to '')
-rw-r--r--unsorted/ParserHelpers-cc.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/unsorted/ParserHelpers-cc.c b/unsorted/ParserHelpers-cc.c
index d56fe4d..fe081ad 100644
--- a/unsorted/ParserHelpers-cc.c
+++ b/unsorted/ParserHelpers-cc.c
@@ -1,8 +1,8 @@
-#include "mwcc_decomp.h"
+#include "parser.h"
Handle definesHandle;
-int Opt_AddStringToDefines(const char *opt, void *str, const char *param) {
+int Opt_AddStringToDefines(const char *opt, void *str, const char *param, int flags) {
AddStringToHandle(&definesHandle, (const char *) str);
if (param)
AddStringToHandle(&definesHandle, param);
@@ -18,7 +18,7 @@ int Opt_DefineSymbol(const char *var, const char *value) {
sprintf(tmp, "{$definec %s %s}\n", var, value ? value : "1");
} else {
sprintf(tmp, "Option '-D|d' is not supported with this plugin");
- CLPReportError(28, tmp);
+ CLPReportError(CLPStr28_WarningText, tmp);
return 0;
}
@@ -26,7 +26,7 @@ int Opt_DefineSymbol(const char *var, const char *value) {
return 1;
}
-int Opt_UndefineSymbol(const char *opt, void *, const char *arg) {
+int Opt_UndefineSymbol(const char *opt, void *, const char *arg, int flags) {
char tmp[300];
if (pTool->LANG == Lang_C_CPP || pTool->LANG == CWFOURCHAR('A','s','m',' ')) {
@@ -35,7 +35,7 @@ int Opt_UndefineSymbol(const char *opt, void *, const char *arg) {
sprintf(tmp, "{$undefc %s}\n", arg);
} else {
sprintf(tmp, "Option -%s is not supported with this plugin", opt);
- CLPReportError(28, tmp);
+ CLPReportError(CLPStr28_WarningText, tmp);
return 0;
}
@@ -43,7 +43,7 @@ int Opt_UndefineSymbol(const char *opt, void *, const char *arg) {
return 1;
}
-int Opt_AddPrefixFile(const char *opt, void *handle, const char *filename) {
+int Opt_AddPrefixFile(const char *opt, void *handle, const char *filename, int flags) {
char tmp[300];
handle = !handle ? &definesHandle : handle;
@@ -60,7 +60,7 @@ int Opt_AddPrefixFile(const char *opt, void *handle, const char *filename) {
snprintf(tmp, sizeof(tmp), "{$I+}\n{$I %s}\n{$I-}\n", filename);
} else {
sprintf(tmp, "Option -%s is not supported with this plugin", opt);
- CLPReportError(28, tmp);
+ CLPReportError(CLPStr28_WarningText, tmp);
return 0;
}
@@ -86,7 +86,7 @@ int Opt_PragmaFalseTrue(const char *, void *flag, const char *, int flags) {
int Opt_PragmaOnOff(const char *, void *flag, const char *arg) {
if (!arg) {
- CLPReportError(34);
+ CLPReportError(CLPStr34_ArgumentsExpected);
return 0;
}
@@ -95,7 +95,7 @@ int Opt_PragmaOnOff(const char *, void *flag, const char *arg) {
} else if (!ustrcmp(arg, "off")) {
*((unsigned char *) flag) = PR_OFF;
} else {
- CLPReportError(12, arg);
+ CLPReportError(CLPStr12, arg);
return 0;
}
@@ -104,7 +104,7 @@ int Opt_PragmaOnOff(const char *, void *flag, const char *arg) {
int Opt_PragmaOffOn(const char *, void *flag, const char *arg) {
if (!arg) {
- CLPReportError(34);
+ CLPReportError(CLPStr34_ArgumentsExpected);
return 0;
}
@@ -113,7 +113,7 @@ int Opt_PragmaOffOn(const char *, void *flag, const char *arg) {
} else if (!ustrcmp(arg, "off")) {
*((unsigned char *) flag) = PR_ON;
} else {
- CLPReportError(12, arg);
+ CLPReportError(CLPStr12, arg);
return 0;
}