[pypy-dev] problems compiling with complex

Armin Rigo arigo at tunes.org
Sat Feb 11 22:07:12 CET 2006

Hi Christian,

On Sat, Feb 11, 2006 at 09:00:11PM +0100, Christian Tismer wrote:
> You are also raising standard exceptions with argumens, which
> is not supported (thanks Samuele).

Raising then is fine, in the sense that you can say

    raise ValueError("some message")

but the message itself is lost in RPython, so you cannot read it back in

    except ValueError, e:
        raise OperationError(space.w_ValueError, space.wrap(e.msg))

Also note that space.float_w() isn't supposed to raise ValueErrors,
either.  It should directly raise the correct OperationError, and you
shouldn't have to worry about catching it.  If it's not the case then
something is wrong with float_w().

A bientot,


More information about the Pypy-dev mailing list