summaryrefslogtreecommitdiff
path: root/gcc/melt-runtime.h
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2011-01-12 15:37:14 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2011-01-12 15:37:14 +0000
commitc2e5af0c39f62744e991d698305250d5986f5cbf (patch)
tree564848d43575565ca1e23af99964e93e1ef0be5e /gcc/melt-runtime.h
parent0985558626d61259298fbf0a80a5bfc1aa5e6faa (diff)
downloadgcc-c2e5af0c39f62744e991d698305250d5986f5cbf.tar.gz
2011-01-12 Basile Starynkevitch <basile@starynkevitch.net>
* melt-runtime.h (meltgc_add_out_cstr_len): New function declaration. (meltgc_add_strbuf_cstr_len): New macro. * melt-runtime.c (meltgc_add_out_cstr_len): New function. (meltgc_add_out_cstr): Call the above one. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@168716 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/melt-runtime.h')
-rw-r--r--gcc/melt-runtime.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/melt-runtime.h b/gcc/melt-runtime.h
index 068ece6395f..ec4fc96ef66 100644
--- a/gcc/melt-runtime.h
+++ b/gcc/melt-runtime.h
@@ -2753,6 +2753,13 @@ void meltgc_add_out_cstr (melt_ptr_t outbuf_p,
const char *str);
#define meltgc_add_strbuf_cstr(Out,Str) meltgc_add_out_cstr(Out,Str)
+/* add safely into OUTBUF the string STR of length SLEN encoded as a C
+ string with backslash escapes */
+void meltgc_add_out_cstr_len (melt_ptr_t outbuf_p,
+ const char *str, int slen);
+#define meltgc_add_strbuf_cstr_len(Out,Str,Slen) \
+ meltgc_add_out_cstr_len(Out,Str,Slen)
+
/* add safely into OUTBUF the string STR encoded as the interior of a
C comment with slash star and star slash replaced by slash plus and
plus slash */