aboutsummaryrefslogtreecommitdiff
path: root/gcc/diagnostic.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/diagnostic.c')
-rw-r--r--gcc/diagnostic.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/diagnostic.c b/gcc/diagnostic.c
index bbf5f5ce7a6..a98bf4a3333 100644
--- a/gcc/diagnostic.c
+++ b/gcc/diagnostic.c
@@ -1128,6 +1128,8 @@ diagnostic_n_impl (location_t location, int opt, int n,
singular_gmsgid, plural_gmsgid, ap, kind);
}
+/* Wrapper around diagnostic_impl taking a variable argument list. */
+
bool
emit_diagnostic (diagnostic_t kind, location_t location, int opt,
const char *gmsgid, ...)
@@ -1140,6 +1142,16 @@ emit_diagnostic (diagnostic_t kind, location_t location, int opt,
return ret;
}
+/* Wrapper around diagnostic_impl taking a va_list parameter. */
+
+bool
+emit_diagnostic_valist (diagnostic_t kind, location_t location, int opt,
+ const char *gmsgid, va_list *ap)
+{
+ rich_location richloc (line_table, location);
+ return diagnostic_impl (&richloc, opt, gmsgid, ap, kind);
+}
+
/* An informative note at LOCATION. Use this for additional details on an error
message. */
void