<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/library/std/src/os/solid/io.rs, branch perf-tmp</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2025-02-14T12:00:13+00:00</updated>
<entry>
<title>Add safe new to NotAllOnes</title>
<updated>2025-02-14T12:00:13+00:00</updated>
<author>
<name>Kornel</name>
<email>kornel@geekhood.net</email>
</author>
<published>2025-02-11T11:04:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=00964aa401214ceab23d232b7d819b9b3286343f'/>
<id>urn:sha1:00964aa401214ceab23d232b7d819b9b3286343f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>std: replace the `FromInner` implementation for addresses with private conversion functions</title>
<updated>2025-02-12T13:13:35+00:00</updated>
<author>
<name>joboet</name>
<email>jonasboettiger@icloud.com</email>
</author>
<published>2025-02-07T17:34:09+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=80c60fe78375cb10a2fed6540dc2b29751fc4263'/>
<id>urn:sha1:80c60fe78375cb10a2fed6540dc2b29751fc4263</id>
<content type='text'>
Having these implementation available crate-wide means that platforms not using sockets for their networking code have to stub out the libc definitions required to support them. This PR moves the conversions to private helper functions that are only available where actually needed.

I also fixed the signature of the function converting from a C socket address to a Rust one: taking a reference to a `sockaddr_storage` resulted in unsound usage inside  `LookupHost::next`, which could create a reference to a structure smaller than `sockaddr_storage`. Thus I've replaced the argument type with a pointer and made the function `unsafe`.
</content>
</entry>
<entry>
<title>std: move network code into `sys`</title>
<updated>2025-02-02T18:12:06+00:00</updated>
<author>
<name>joboet</name>
<email>jonasboettiger@icloud.com</email>
</author>
<published>2025-02-02T17:53:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=4f834264ab8d0cb95ac7972532661c84a154667e'/>
<id>urn:sha1:4f834264ab8d0cb95ac7972532661c84a154667e</id>
<content type='text'>
As per #117276, this PR moves `sys_common::net` and the `sys::pal::net` into the newly created `sys::net` module. In order to support #135141, I've moved all the current network code into a separate `connection` module, future functions like `hostname` can live in separate modules.

I'll probably do a follow-up PR and clean up some of the actual code, this is mostly just a reorganization.
</content>
</entry>
<entry>
<title>Update a bunch of library types for MCP807</title>
<updated>2025-01-10T07:47:11+00:00</updated>
<author>
<name>Scott McMurray</name>
<email>scottmcm@users.noreply.github.com</email>
</author>
<published>2025-01-08T03:35:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=6f2a78345ee7f55c5ce33fd7b9804c665c646dd2'/>
<id>urn:sha1:6f2a78345ee7f55c5ce33fd7b9804c665c646dd2</id>
<content type='text'>
This greatly reduces the number of places that actually use the `rustc_layout_scalar_valid_range_*` attributes down to just 3:
```
library/core\src\ptr\non_null.rs
68:#[rustc_layout_scalar_valid_range_start(1)]

library/core\src\num\niche_types.rs
19:        #[rustc_layout_scalar_valid_range_start($low)]
20:        #[rustc_layout_scalar_valid_range_end($high)]
```

Everything else -- PAL Nanoseconds, alloc's `Cap`, niched FDs, etc -- all just wrap those `niche_types` types.
</content>
</entry>
<entry>
<title>Rollup merge of #127586 - zachs18:more-must-use, r=cuviper</title>
<updated>2024-08-03T09:17:42+00:00</updated>
<author>
<name>Matthias Krüger</name>
<email>matthias.krueger@famsik.de</email>
</author>
<published>2024-08-03T09:17:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1f700139f8d5cb458679e6f8c0a0aa247b56c79d'/>
<id>urn:sha1:1f700139f8d5cb458679e6f8c0a0aa247b56c79d</id>
<content type='text'>
Add `#[must_use]` to some `into_raw*` functions.

cc #121287

r? ``@cuviper``

Adds `#[must_use = "losing the pointer will leak memory"]`[^1] to `Box::into_raw(_with_allocator)`, `Vec::into_raw_parts(_with_alloc)`, `String::into_raw_parts`[^2], and `rc::{Rc, Weak}::into_raw_with_allocator` (Rc's normal `into_raw` and all of `Arc`'s `into_raw*`s are already `must_use`).

Adds `#[must_use = "losing the raw &lt;resource name may leak resources"]` to `IntoRawFd::into_raw_fd`, `IntoRawSocket::into_raw_socket`, and `IntoRawHandle::into_raw_handle`.

[^1]: "*will* leak memory" may be too-strong wording (since `Box`/`Vec`/`String`/`rc::Weak` might not have a backing allocation), but I left it as-is for simplicity and consistency.

[^2]: `String::into_raw_parts`'s `must_use` message is changed from the previous (possibly misleading) "`self` will be dropped if the result is not used".
</content>
</entry>
<entry>
<title>Reformat `use` declarations.</title>
<updated>2024-07-28T22:26:52+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2024-07-28T22:13:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=84ac80f1921afc243d71fd0caaa4f2838c294102'/>
<id>urn:sha1:84ac80f1921afc243d71fd0caaa4f2838c294102</id>
<content type='text'>
The previous commit updated `rustfmt.toml` appropriately. This commit is
the outcome of running `x fmt --all` with the new formatting options.
</content>
</entry>
<entry>
<title>Fix doc nits</title>
<updated>2024-07-26T12:26:33+00:00</updated>
<author>
<name>John Arundel</name>
<email>john@bitfieldconsulting.com</email>
</author>
<published>2024-07-15T11:26:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=a19472a93e2eecce1477011fa9f7ec49b45ca164'/>
<id>urn:sha1:a19472a93e2eecce1477011fa9f7ec49b45ca164</id>
<content type='text'>
Many tiny changes to stdlib doc comments to make them consistent (for example
"Returns foo", rather than "Return foo", per RFC1574), adding missing periods, paragraph
breaks, backticks for monospace style, and other minor nits.

https://github.com/rust-lang/rfcs/blob/master/text/1574-more-api-documentation-conventions.md#appendix-a-full-conventions-text
</content>
</entry>
<entry>
<title>Rollup merge of #127733 - GrigorenkoPV:don't-forget, r=Amanieu</title>
<updated>2024-07-24T16:00:39+00:00</updated>
<author>
<name>Matthias Krüger</name>
<email>matthias.krueger@famsik.de</email>
</author>
<published>2024-07-24T16:00:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=34abb9647c58650fd6554dff91c3332e06ee9ace'/>
<id>urn:sha1:34abb9647c58650fd6554dff91c3332e06ee9ace</id>
<content type='text'>
Replace some `mem::forget`'s with `ManuallyDrop`

              &gt; but I would like to see a larger effort to replace all uses of `mem::forget`.

_Originally posted by `@saethlin` in https://github.com/rust-lang/rust/issues/127584#issuecomment-2226087767_

So,
r? `@saethlin`

Sorry, I have finished writing all of this before I got your response.
</content>
</entry>
<entry>
<title>kmc-solid: forbid(unsafe_op_in_unsafe_fn)</title>
<updated>2024-07-19T20:46:06+00:00</updated>
<author>
<name>Jubilee Young</name>
<email>workingjubilee@gmail.com</email>
</author>
<published>2024-07-17T19:57:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1d83da88473e72717c089a389adcea1c53d4c9f8'/>
<id>urn:sha1:1d83da88473e72717c089a389adcea1c53d4c9f8</id>
<content type='text'>
</content>
</entry>
<entry>
<title>lib: replace some `mem::forget`'s with `ManuallyDrop`</title>
<updated>2024-07-15T19:01:09+00:00</updated>
<author>
<name>Pavel Grigorenko</name>
<email>GrigorenkoPV@ya.ru</email>
</author>
<published>2024-07-14T19:17:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f6fe7e49a2bc2ad14513aa609b67e188470309f6'/>
<id>urn:sha1:f6fe7e49a2bc2ad14513aa609b67e188470309f6</id>
<content type='text'>
</content>
</entry>
</feed>
