mirror of
https://github.com/HeyPuter/firefox.git
synced 2026-11-30 14:17:36 -10:00
This patch adds a series of fallible methods for the rust ns[C]String bindings, as well as the `set_length` method, which is the same as the `SetLength` method in C++. `set_length` is marked as unsafe. The decision was made to make the fallible methods seperate from the infallible methods, and to use seperate Rust->C++ bindings for each of them, rather than only binding the fallible bindings, and unwrapping them in rust-land. This is to try to match the C++ API as closely as possible, and to ensure that the behavior matches. MozReview-Commit-ID: FkSomkFUFGD