The projects in C++ that forbid exceptions are doing so not because of
some prejudice, but because exceptions in C++ are unsafe. In Java
standard library exceptions are ubiquitous.

On Thu, May 29, 2014 at 2:32 PM, Patrick Walton <[email protected]> wrote:
> Exceptions, and stack unwinding in general, are not acceptable in many
> systems projects. Many, perhaps most, C++ projects turn off exceptions. This
> is true of all browser engines I know of, as well as games and OS
> kernels--essentially the niches where C++ is the strongest. The primary
> reason is that the unwind tables are large, and unwinding can inhibit
> optimizations.
>
> If we made the standard library require exceptions, then it would be harder
> to use Rust in those niches, and it would compromise the goals of Rust as a
> systems language. Therefore, we have to design our APIs to not require
> exceptions.
>
> Patrick
>
> _______________________________________________
> Rust-dev mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/rust-dev
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to