[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.dsdp.rtsc] Re: Re-throwing an error

Error_raise calls Error_init internally. Also, the docs state:
"If Error_raise is called more than once on an Error_Block object, the previous error information is overwritten; only the last error is retained in the Error_Block object."


http://rtsc.eclipse.org/cdoc-tip/xdc/runtime/Error.html#raise

I guess we could explicitly say that Error_raise always call Error_init, but on the other hand, that's not the only way to ensure that the Error_Block object is completely overwritten by subsequent Error_raise calls. Even now, Error_raise writes into each field of the Error_Block object, so the call to Error_init is redundant.
I would rather leave docs as they are and leave the implementation details out of the docs, in case that the internal call to Error_raise gets removed to save a couple of cycles.