Re: [cairo] Re: cairo c++ bindings



On Thu, 24 Nov 2005 15:13:20 +0100 (CET), "Murray Cumming" wrote:
> At the moment, it throws exceptions when a function returns a bad status.
> 
> For functions that don't return a status, maybe it should call
> *_get_status() after each call. Is that what the C coders are meant to do?

No. C coders are not meant to call _get_status repeatedly. What
happens is that if _get_status would return an error status then
basically all of that object's functions become NOOPs. That is, it is
still safe to call functions on that object and defer the _get_status
error checking until a convenient time.

If binding to a language that supports exceptions it probably does
make sense to call _get_status after each call and throw exceptions.

-Carl

Attachment: pgp8cuVLfbpJ2.pgp
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]