<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/library/std/src/ffi, branch 1.71.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.71.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.71.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2023-04-12T17:27:18+00:00</updated>
<entry>
<title>remove some unneeded imports</title>
<updated>2023-04-12T17:27:18+00:00</updated>
<author>
<name>KaDiWa</name>
<email>kalle.wachsmuth@gmail.com</email>
</author>
<published>2022-08-09T00:14:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ad2b34d0e37e2f968f226e2401bcb894207ca1c5'/>
<id>urn:sha1:ad2b34d0e37e2f968f226e2401bcb894207ca1c5</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Guarantee `try_reserve` preserves the contents on error</title>
<updated>2022-08-09T16:51:38+00:00</updated>
<author>
<name>YOSHIOKA Takuma</name>
<email>nop_thread@nops.red</email>
</author>
<published>2022-08-09T16:51:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=2bb7e1e6edf58c39faabb67cfab63dd8109d8055'/>
<id>urn:sha1:2bb7e1e6edf58c39faabb67cfab63dd8109d8055</id>
<content type='text'>
Update doc comments to make the guarantee explicit. However, some
implementations does not have the statement though.

* `HashMap`, `HashSet`: require guarantees on hashbrown side.
* `PathBuf`: simply redirecting to `OsString`.

Fixes #99606.
</content>
</entry>
<entry>
<title>Rollup merge of #97915 - tbu-:pr_os_string_fmt_write, r=joshtriplett</title>
<updated>2022-07-17T04:08:48+00:00</updated>
<author>
<name>Yuki Okushi</name>
<email>jtitor@2k36.org</email>
</author>
<published>2022-07-17T04:08:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=48cf43b752282d512be1a1cb664166698b5d63a8'/>
<id>urn:sha1:48cf43b752282d512be1a1cb664166698b5d63a8</id>
<content type='text'>
Implement `fmt::Write` for `OsString`

This allows to format into an `OsString` without unnecessary
allocations. E.g.

```
let mut temp_filename = path.into_os_string();
write!(&amp;mut temp_filename, ".tmp.{}", process::id());
```
</content>
</entry>
<entry>
<title>Update `since` version to 1.64</title>
<updated>2022-07-16T21:36:48+00:00</updated>
<author>
<name>Josh Triplett</name>
<email>josh@joshtriplett.org</email>
</author>
<published>2022-07-16T21:36:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3855e868738a847f1e38a6157590aa1a197604ea'/>
<id>urn:sha1:3855e868738a847f1e38a6157590aa1a197604ea</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Stabilize `core::ffi::CStr`, `alloc::ffi::CString`, and friends</title>
<updated>2022-07-15T10:10:35+00:00</updated>
<author>
<name>Josh Triplett</name>
<email>josh@joshtriplett.org</email>
</author>
<published>2022-07-15T10:10:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d6b7480c2a086d9284cfd4ed3f3e3612880a75d7'/>
<id>urn:sha1:d6b7480c2a086d9284cfd4ed3f3e3612880a75d7</id>
<content type='text'>
Stabilize the `core_c_str` and `alloc_c_string` feature gates.

Change `std::ffi` to re-export these types rather than creating type
aliases, since they now have matching stability.
</content>
</entry>
<entry>
<title>Rollup merge of #98315 - joshtriplett:stabilize-core-ffi-c, r=Mark-Simulacrum</title>
<updated>2022-07-14T08:44:20+00:00</updated>
<author>
<name>Dylan DPC</name>
<email>99973273+Dylan-DPC@users.noreply.github.com</email>
</author>
<published>2022-07-14T08:44:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=103b8602b7e3cfc8301ab9e0981563bde3789ea7'/>
<id>urn:sha1:103b8602b7e3cfc8301ab9e0981563bde3789ea7</id>
<content type='text'>
Stabilize `core::ffi:c_*` and rexport in `std::ffi`

This only stabilizes the base types, not the non-zero variants, since
those have their own separate tracking issue and have not gone through
FCP to stabilize.
</content>
</entry>
<entry>
<title>Stabilize `core::ffi:c_*` and rexport in `std::ffi`</title>
<updated>2022-07-14T02:28:20+00:00</updated>
<author>
<name>Josh Triplett</name>
<email>josh@joshtriplett.org</email>
</author>
<published>2022-06-20T20:59:58+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d431338b2521dee00b0758e1609e8af7320515d4'/>
<id>urn:sha1:d431338b2521dee00b0758e1609e8af7320515d4</id>
<content type='text'>
This only stabilizes the base types, not the non-zero variants, since
those have their own separate tracking issue and have not gone through
FCP to stabilize.
</content>
</entry>
<entry>
<title>Fix documentation for with_capacity and reserve families of methods</title>
<updated>2022-06-19T19:46:49+00:00</updated>
<author>
<name>jmaargh</name>
<email>jmaargh@gmail.com</email>
</author>
<published>2022-04-09T15:42:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=95dc353006c23a4493b3d08ba33680e51c2107c8'/>
<id>urn:sha1:95dc353006c23a4493b3d08ba33680e51c2107c8</id>
<content type='text'>
Documentation for the following methods

    with_capacity
    with_capacity_in
    with_capacity_and_hasher
    reserve
    reserve_exact
    try_reserve
    try_reserve_exact

was inconsistent and often not entirely correct where they existed on the following types

    Vec
    VecDeque
    String
    OsString
    PathBuf
    BinaryHeap
    HashSet
    HashMap
    BufWriter
    LineWriter

since the allocator is allowed to allocate more than the requested capacity in all such cases, and will frequently "allocate" much more in the case of zero-sized types (I also checked BufReader, but there the docs appear to be accurate as it appears to actually allocate the exact capacity).

Some effort was made to make the documentation more consistent between types as well.

Fix with_capacity* methods for Vec

Fix *reserve*  methods for Vec

Fix docs for *reserve* methods of VecDeque

Fix docs for String::with_capacity

Fix docs for *reserve* methods of String

Fix docs for OsString::with_capacity

Fix docs for *reserve* methods on OsString

Fix docs for with_capacity* methods on HashSet

Fix docs for *reserve methods of HashSet

Fix docs for with_capacity* methods of HashMap

Fix docs for *reserve methods on HashMap

Fix expect messages about OOM in doctests

Fix docs for BinaryHeap::with_capacity

Fix docs for *reserve* methods of BinaryHeap

Fix typos

Fix docs for with_capacity on BufWriter and LineWriter

Fix consistent use of `hasher` between `HashMap` and `HashSet`

Fix warning in doc test

Add test for capacity of vec with ZST

Fix doc test error
</content>
</entry>
<entry>
<title>Rollup merge of #95392 - Xuanwo:stablize_try_reserve_2, r=dtolnay</title>
<updated>2022-06-17T10:21:46+00:00</updated>
<author>
<name>Dylan DPC</name>
<email>99973273+Dylan-DPC@users.noreply.github.com</email>
</author>
<published>2022-06-17T10:21:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=b516806774e3ee85abc54105ad6edd13deaa34a2'/>
<id>urn:sha1:b516806774e3ee85abc54105ad6edd13deaa34a2</id>
<content type='text'>
std: Stabilize feature try_reserve_2

This PR intends to stabilize feature `try_reserve_2`, closes https://github.com/rust-lang/rust/issues/91789

This PR will also replace the previous PR: https://github.com/rust-lang/rust/pull/95139
</content>
</entry>
<entry>
<title>std: Stabilize feature try_reserve_2</title>
<updated>2022-06-16T01:30:34+00:00</updated>
<author>
<name>Xuanwo</name>
<email>github@xuanwo.io</email>
</author>
<published>2022-03-28T02:01:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=324286f1019bcf9abef19543d4bb8749d9f91ed9'/>
<id>urn:sha1:324286f1019bcf9abef19543d4bb8749d9f91ed9</id>
<content type='text'>
Signed-off-by: Xuanwo &lt;github@xuanwo.io&gt;
</content>
</entry>
</feed>
