On Monday, 29 February 2016 at 23:41:51 UTC, Chris Wright wrote:
On Mon, 29 Feb 2016 21:55:49 +0000, Jirka wrote:

Yes, that I understand, but the "new" operator can lead to other system calls (?), could they overwrite it?

Yes. Most obviously, the GC uses malloc, which will set errno to ENOMEM on failure.

Ok, that would throw some OOM exception instead so I wouldn't need to bother with it, is there something else in the GC that would override it during class instance allocation? I am finding it weird that ErrnoException doesn't let you specify the errno value explicitly, you usually check it in your code anyway (e.g. for EINTR and repeat the operation and not throw this error).

Reply via email to