diff options
Diffstat (limited to 'vhdlparser/vhdlstring.h')
-rw-r--r-- | vhdlparser/vhdlstring.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vhdlparser/vhdlstring.h b/vhdlparser/vhdlstring.h index 1980cf5..f15ef6c 100644 --- a/vhdlparser/vhdlstring.h +++ b/vhdlparser/vhdlstring.h @@ -90,7 +90,8 @@ class VhdlString char & operator[](int i) { return m_str[i]; } const char &operator[](int i) const { return m_str[i]; } void clear() { free(m_str); init(); } - VhdlString operator+=(char c) { char s[2]; s[0]=c; s[1]=0; return append(s); } + VhdlString &operator+=(char c) { char s[2]; s[0]=c; s[1]=0; return append(s); } + VhdlString &operator+=(const char *s) { return append(s); } private: void init() { m_str=(char*)calloc(1,1); m_len=0; } |