T_STRING is now const char * instead of char *
Fixes Guile constant wrappers removing -Wwrite-strings g++ warning.
This commit is contained in:
parent
72afb74f47
commit
9c7d014389
2 changed files with 2 additions and 1 deletions
|
|
@ -1350,7 +1350,7 @@ public:
|
||||||
Printv(f_header, tm, "\n", NIL);
|
Printv(f_header, tm, "\n", NIL);
|
||||||
} else {
|
} else {
|
||||||
// Create variable and assign it a value
|
// Create variable and assign it a value
|
||||||
Printf(f_header, "static %s = %s;\n", SwigType_lstr(nctype, var_name), rvalue);
|
Printf(f_header, "static %s = %s;\n", SwigType_str(type, var_name), rvalue);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
/* Hack alert: will cleanup later -- Dave */
|
/* Hack alert: will cleanup later -- Dave */
|
||||||
|
|
|
||||||
|
|
@ -131,6 +131,7 @@ SwigType *NewSwigType(int t) {
|
||||||
break;
|
break;
|
||||||
case T_STRING: {
|
case T_STRING: {
|
||||||
SwigType *t = NewString("char");
|
SwigType *t = NewString("char");
|
||||||
|
SwigType_add_qualifier(t, "const");
|
||||||
SwigType_add_pointer(t);
|
SwigType_add_pointer(t);
|
||||||
return t;
|
return t;
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue