Well like I've already explained I mean argout. I'd just got it wrong in the first message. Has it never happened to you?

----- Ursprungsmeddelande -----
> Tomas Walch wrote:
> > This is my (simpified) situation:
> >
> > In my C++ code I have methods like this:
> >
> > bool SetValue(const MyString& value);
> > bool GetValue(MyString& value);
> >
> > I have written specialized typemaps that map between MyStrings and
> Python str like this
> >
> > %typemap(in) const MyString& {
> > ...
> > }
> >
> > %typemap(in, numinputs=0) MyString& OUTPUT  (MyString temp) {
> > $1 = &temp;
> > }
> >
> > %typemap(attrout) MyString& OUTPUT {
> > ... // packs a tuple of bool and str
> > }
> >
> > The translation code all works fine
> > I apply the typemaps like this:
> >
> > %apply const MyString& { const MyString& value };
> > %apply MyString& OUTPUT { MyString& value }
> >
> > My problem is that the attrout typemap is also applied to  'const
> MyString& value', which I don't want.
> > So when I call SetValue from Python it returns a tupe of (bool, str),
> like GetValue...
> >
> There is no typemap named 'attrout', so I've no idea what is going on!
>
> William
>