modpython: Make strings to be stringable.
Now you can use str() on objects of znc.String. The same is true for arguments which represent CString&.
This commit is contained in:
1 parent
63250c2b47
commit
45209eca33
1 file changed
+12
@@ -106,6 +106,18 @@ public:
|
||||
CString s;
|
||||
};
|
||||
|
||||
%extend CPyRetString {
|
||||
CString __str__() {
|
||||
return $self->s;
|
||||
}
|
||||
};
|
||||
|
||||
%extend String {
|
||||
CString __str__() {
|
||||
return $self->s;
|
||||
}
|
||||
};
|
||||
|
||||
%extend CModule {
|
||||
MCString_iter BeginNV_() {
|
||||
return MCString_iter($self->BeginNV());
|
||||
|
||||
Reference in new issue
Block a user