From 5cafbdaa82bc934265cf70d00786012dd3ccda4b Mon Sep 17 00:00:00 2001 From: Marcelo Matus Date: Mon, 6 Mar 2006 18:17:06 +0000 Subject: [PATCH] fix _swig_repr, as reported by Robin git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8968 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- SWIG/Source/Modules/python.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/SWIG/Source/Modules/python.cxx b/SWIG/Source/Modules/python.cxx index 26760a408..eff978de6 100644 --- a/SWIG/Source/Modules/python.cxx +++ b/SWIG/Source/Modules/python.cxx @@ -151,8 +151,8 @@ static const char *usage3 = (char *)"\ -safecstrings - Use safer (but slower) C string mapping, generating copies from Python -> C/C++\n\ -threads - Add thread support for all the interface\n\ -O - Enable all the optimizations options: \n\ - -modern -fastdispatch -dirvtable -nosafecstrings -fvirtual \n\ - -noproxydel -fastproxy -fastinit -fastunpack -modernargs -nobuildnone \n\ + -modern -fastdispatch -dirvtable -nosafecstrings -fvirtual -noproxydel \n\ + -fastproxy -fastinit -fastunpack -fastquery -modernargs -nobuildnone \n\ \n"; class PYTHON : public Language { @@ -740,9 +740,9 @@ public: Printv(f_shadow, "def _swig_repr(self):\n", - tab4, "try: strthis = \"at 0x%x\" %( self.this, )\n", + tab4, "try: strthis = \"proxy of \" + self.this.__repr__()\n", tab4, "except: strthis = \"\"\n", - tab4, "return \"<%s.%s; proxy of C++ swig::PySwigIterator instance %s>\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", + tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); if (!classic) {