From 686c09d54408562c7df08b06fb89c4efe5152704 Mon Sep 17 00:00:00 2001 From: Sebastian Geerken Date: Wed, 20 Mar 2013 12:25:24 +0100 Subject: Some cleanup. --- lout/misc.hh | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lout/misc.hh') diff --git a/lout/misc.hh b/lout/misc.hh index cff8e05b..2ed5e1b0 100644 --- a/lout/misc.hh +++ b/lout/misc.hh @@ -515,6 +515,11 @@ public: * about memory management. */ inline void append(const char *str) { appendNoCopy(strdup(str)); } + inline void appendInt(int n) + { char buf[32]; sprintf (buf, "%d", n); append (buf); } + inline void appendPointer(void *p) + { char buf[32]; sprintf (buf, "%p", p); append (buf); } + inline void appendBool(bool b) { append (b ? "true" : "false"); } void appendNoCopy(char *str); const char *getChars(); void clear (); -- cgit v1.2.3