+
+// A set of macros to make using %rename easier, since %name has been
+// deprecated...
+%define %Rename(newname, type, decl)
+ %rename(newname) decl;
+ type decl
+%enddef
+
+%define %RenameCtor(newname, decl)
+ %rename(newname) decl;
+ decl
+%enddef
+
+#ifdef _DO_FULL_DOCS
+ %define %RenameDocCtor(newname, docstr, details, decl)
+ %feature("docstring") decl docstr details;
+ %rename(newname) decl;
+ decl
+ %enddef
+#else
+ %define %RenameDocCtor(newname, docstr, details, decl)
+ %feature("docstring") decl docstr;
+ %rename(newname) decl;
+ decl
+ %enddef
+#endif
+