Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

std: Stabilize/deprecate features for 1.4 #28339

Merged
merged 1 commit into from Sep 13, 2015

Conversation

Projects
None yet
9 participants
@alexcrichton
Copy link
Member

alexcrichton commented Sep 10, 2015

The FCP is coming to a close and 1.4 is coming out soon, so this brings in the
libs team decision for all library features this cycle.

Stabilized APIs:

  • <Box<str>>::into_string
  • Arc::downgrade
  • Arc::get_mut
  • Arc::make_mut
  • Arc::try_unwrap
  • Box::from_raw
  • Box::into_raw
  • CStr::to_str
  • CStr::to_string_lossy
  • CString::from_raw
  • CString::into_raw
  • IntoRawFd::into_raw_fd
  • IntoRawFd
  • IntoRawHandle::into_raw_handle
  • IntoRawHandle
  • IntoRawSocket::into_raw_socket
  • IntoRawSocket
  • Rc::downgrade
  • Rc::get_mut
  • Rc::make_mut
  • Rc::try_unwrap
  • Result::expect
  • String::into_boxed_slice
  • TcpSocket::read_timeout
  • TcpSocket::set_read_timeout
  • TcpSocket::set_write_timeout
  • TcpSocket::write_timeout
  • UdpSocket::read_timeout
  • UdpSocket::set_read_timeout
  • UdpSocket::set_write_timeout
  • UdpSocket::write_timeout
  • Vec::append
  • Vec::split_off
  • VecDeque::append
  • VecDeque::retain
  • VecDeque::split_off
  • rc::Weak::upgrade
  • rc::Weak
  • slice::Iter::as_slice
  • slice::IterMut::into_slice
  • str::CharIndices::as_str
  • str::Chars::as_str
  • str::split_at_mut
  • str::split_at
  • sync::Weak::upgrade
  • sync::Weak
  • thread::park_timeout
  • thread::sleep

Deprecated APIs

  • BTreeMap::with_b
  • BTreeSet::with_b
  • Option::as_mut_slice
  • Option::as_slice
  • Result::as_mut_slice
  • Result::as_slice
  • f32::from_str_radix
  • f64::from_str_radix

Closes #27277
Closes #27718
Closes #27736
Closes #27764
Closes #27765
Closes #27766
Closes #27767
Closes #27768
Closes #27769
Closes #27771
Closes #27773
Closes #27775
Closes #27776
Closes #27785
Closes #27792
Closes #27795
Closes #27797

@rust-highfive

This comment has been minimized.

Copy link
Collaborator

rust-highfive commented Sep 10, 2015

r? @pcwalton

(rust_highfive has picked a reviewer for you, use r? to override)

@alexcrichton alexcrichton force-pushed the alexcrichton:stabilize-1.4 branch from b384ce1 to b7a319d Sep 10, 2015

@alexcrichton

This comment has been minimized.

Copy link
Member Author

alexcrichton commented Sep 10, 2015

@rust-highfive rust-highfive assigned aturon and unassigned pcwalton Sep 10, 2015

@alexcrichton alexcrichton force-pushed the alexcrichton:stabilize-1.4 branch 3 times, most recently from 1db2831 to 68e1b65 Sep 10, 2015

@@ -263,7 +261,8 @@ impl<T> Rc<T> {
}

/// Checks if `Rc::try_unwrap` would return `Ok`.
#[unstable(feature = "rc_would_unwrap", reason = "just added for niche usecase",
#[unstable(feature = "rc_would_unwrap",
reason = "just added for niche usecase",
issue = "27718")]

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

This needs a new issue number: this PR closes 27718.

@@ -733,7 +731,7 @@ impl String {
/// Converts the string into `Box<str>`.
///
/// Note that this will drop any excess capacity.
#[unstable(feature = "box_str",
#[unstable(feature = "box_str2",
reason = "recently added, matches RFC",
issue = "27785")]

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

Also needs a new issue number.

This comment has been minimized.

@alexcrichton

alexcrichton Sep 11, 2015

Author Member

This is deprecated, so a new issue isn't necessary in this case.

@@ -205,7 +205,7 @@ impl CString {
/// The only appropriate argument is a pointer obtained by calling
/// `into_ptr`. The length of the string will be recalculated
/// using the pointer.
#[unstable(feature = "cstr_memory", reason = "recently added",
#[unstable(feature = "cstr_memory2", reason = "recently added",
issue = "27769")]

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

Also needs a new issue number

@@ -154,8 +164,7 @@ impl TcpStream {
/// # Note
///
/// Some platforms do not provide access to the current timeout.
#[unstable(feature = "socket_timeout", reason = "RFC 1047 - recently added",
issue = "27773")]
#[stable(feature = "socket_timeout", since = "1.4.0")]

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

The fact that this never works on Windows suggests that maybe we shouldn't be stabilizing it...

This comment has been minimized.

@sfackler

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

Huh... https://msdn.microsoft.com/en-us/library/windows/desktop/ms738544%28v=vs.85%29.aspx says it doesn't work. But if the test works, then it must work, I guess. Weird.

This comment has been minimized.

@alexcrichton

alexcrichton Sep 11, 2015

Author Member

It's also explicitly stated in the documentation:

Some platforms do not provide access to the current timeout

@Gankro

This comment has been minimized.

Copy link
Contributor

Gankro commented Sep 10, 2015

I thought people didn't like append as a name?

/// Platforms may return a different error code whenever a read times out as
/// a result of setting this option. For example Unix typically returns an
/// error of the kind `WouldBlock`, but Windows may return `TimedOut`.
#[stable(feature = "socket_timeout", since = "1.4.0")]

This comment has been minimized.

@eefriedman

eefriedman Sep 10, 2015

Contributor

Are we really sure this is ready to be stabilized? I'm not sure the questions brought up in #27773 have been sufficiently addressed.

If you're sure this is ready to be stabilized, for the comment, I would suggest something more like "The exact meaning of the timeout is platform-specific; reads may block for longer than the given duration. There is no portable way to detect if a read has timed out due to this timeout; the connection should be closed if a read fails with WouldBlock or TimedOut."

This comment has been minimized.

@alexcrichton

alexcrichton Sep 11, 2015

Author Member

Yes, the purpose of this function is to bind the SO_RCVTIMEO option, and it's what it's doing on all platforms. Whether or not this is exactly what you want for your application will depend on use cases, but this provides the appropriate Rust interface to getting/setting these options.

This comment has been minimized.

@aturon

aturon Sep 11, 2015

Member

To elaborate on this a bit: we discussed #27773 extensively in the libs team meeting, and I've written up the results of that discussion in a new comment there.

@alexcrichton

This comment has been minimized.

Copy link
Member Author

alexcrichton commented Sep 11, 2015

@Gankro

I thought people didn't like append as a name?

We discussed this in the libs team meaning, but the ship has long sailed on this. These functions have gone through RFCs multiple times almost, and the functionality is already stable on LinkedList.

@alexcrichton alexcrichton force-pushed the alexcrichton:stabilize-1.4 branch from 68e1b65 to b20b26f Sep 11, 2015

std: Stabilize/deprecate features for 1.4
The FCP is coming to a close and 1.4 is coming out soon, so this brings in the
libs team decision for all library features this cycle.

Stabilized APIs:

* `<Box<str>>::into_string`
* `Arc::downgrade`
* `Arc::get_mut`
* `Arc::make_mut`
* `Arc::try_unwrap`
* `Box::from_raw`
* `Box::into_raw`
* `CStr::to_str`
* `CStr::to_string_lossy`
* `CString::from_raw`
* `CString::into_raw`
* `IntoRawFd::into_raw_fd`
* `IntoRawFd`
* `IntoRawHandle::into_raw_handle`
* `IntoRawHandle`
* `IntoRawSocket::into_raw_socket`
* `IntoRawSocket`
* `Rc::downgrade`
* `Rc::get_mut`
* `Rc::make_mut`
* `Rc::try_unwrap`
* `Result::expect`
* `String::into_boxed_slice`
* `TcpSocket::read_timeout`
* `TcpSocket::set_read_timeout`
* `TcpSocket::set_write_timeout`
* `TcpSocket::write_timeout`
* `UdpSocket::read_timeout`
* `UdpSocket::set_read_timeout`
* `UdpSocket::set_write_timeout`
* `UdpSocket::write_timeout`
* `Vec::append`
* `Vec::split_off`
* `VecDeque::append`
* `VecDeque::retain`
* `VecDeque::split_off`
* `rc::Weak::upgrade`
* `rc::Weak`
* `slice::Iter::as_slice`
* `slice::IterMut::into_slice`
* `str::CharIndices::as_str`
* `str::Chars::as_str`
* `str::split_at_mut`
* `str::split_at`
* `sync::Weak::upgrade`
* `sync::Weak`
* `thread::park_timeout`
* `thread::sleep`

Deprecated APIs

* `BTreeMap::with_b`
* `BTreeSet::with_b`
* `Option::as_mut_slice`
* `Option::as_slice`
* `Result::as_mut_slice`
* `Result::as_slice`
* `f32::from_str_radix`
* `f64::from_str_radix`

Closes #27277
Closes #27718
Closes #27736
Closes #27764
Closes #27765
Closes #27766
Closes #27767
Closes #27768
Closes #27769
Closes #27771
Closes #27773
Closes #27775
Closes #27776
Closes #27785
Closes #27792
Closes #27795
Closes #27797
@aturon

This comment has been minimized.

Copy link
Member

aturon commented Sep 11, 2015

@Gankro

I thought people didn't like append as a name?

We discussed this in the libs team meaning, but the ship has long sailed on this. These functions have gone through RFCs multiple times almost, and the functionality is already stable on LinkedList.

In particular, if we want to rename, we have to deal with the existing stable functionality. In general, we signed off on completing the collection reform RFC implementation by stabilizing consistent APIs across the collections where they're appropriate.

@aturon

This comment has been minimized.

Copy link
Member

aturon commented Sep 11, 2015

OK, I've checked this over, and r=me -- but I want to give others a bit more time to comment before we send to bors.

@Gankro

This comment has been minimized.

Copy link
Contributor

Gankro commented Sep 11, 2015

shrug works for me

@Gankro

This comment has been minimized.

Copy link
Contributor

Gankro commented Sep 11, 2015

Wait

Or we could deprecate LinkedList

HMMM???

@alexcrichton alexcrichton force-pushed the alexcrichton:stabilize-1.4 branch from b20b26f to f0b1326 Sep 13, 2015

@alexcrichton

This comment has been minimized.

Copy link
Member Author

alexcrichton commented Sep 13, 2015

@bors: r=aturon

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Sep 13, 2015

📌 Commit f0b1326 has been approved by aturon

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Sep 13, 2015

⌛️ Testing commit f0b1326 with merge cedbd99...

bors added a commit that referenced this pull request Sep 13, 2015

Auto merge of #28339 - alexcrichton:stabilize-1.4, r=aturon
The FCP is coming to a close and 1.4 is coming out soon, so this brings in the
libs team decision for all library features this cycle.

Stabilized APIs:

* `<Box<str>>::into_string`
* `Arc::downgrade`
* `Arc::get_mut`
* `Arc::make_mut`
* `Arc::try_unwrap`
* `Box::from_raw`
* `Box::into_raw`
* `CStr::to_str`
* `CStr::to_string_lossy`
* `CString::from_raw`
* `CString::into_raw`
* `IntoRawFd::into_raw_fd`
* `IntoRawFd`
* `IntoRawHandle::into_raw_handle`
* `IntoRawHandle`
* `IntoRawSocket::into_raw_socket`
* `IntoRawSocket`
* `Rc::downgrade`
* `Rc::get_mut`
* `Rc::make_mut`
* `Rc::try_unwrap`
* `Result::expect`
* `String::into_boxed_slice`
* `TcpSocket::read_timeout`
* `TcpSocket::set_read_timeout`
* `TcpSocket::set_write_timeout`
* `TcpSocket::write_timeout`
* `UdpSocket::read_timeout`
* `UdpSocket::set_read_timeout`
* `UdpSocket::set_write_timeout`
* `UdpSocket::write_timeout`
* `Vec::append`
* `Vec::split_off`
* `VecDeque::append`
* `VecDeque::retain`
* `VecDeque::split_off`
* `rc::Weak::upgrade`
* `rc::Weak`
* `slice::Iter::as_slice`
* `slice::IterMut::into_slice`
* `str::CharIndices::as_str`
* `str::Chars::as_str`
* `str::split_at_mut`
* `str::split_at`
* `sync::Weak::upgrade`
* `sync::Weak`
* `thread::park_timeout`
* `thread::sleep`

Deprecated APIs

* `BTreeMap::with_b`
* `BTreeSet::with_b`
* `Option::as_mut_slice`
* `Option::as_slice`
* `Result::as_mut_slice`
* `Result::as_slice`
* `f32::from_str_radix`
* `f64::from_str_radix`

Closes #27277
Closes #27718
Closes #27736
Closes #27764
Closes #27765
Closes #27766
Closes #27767
Closes #27768
Closes #27769
Closes #27771
Closes #27773
Closes #27775
Closes #27776
Closes #27785
Closes #27792
Closes #27795
Closes #27797

@bors bors merged commit f0b1326 into rust-lang:master Sep 13, 2015

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details

@bluss bluss added the relnotes label Sep 15, 2015

@alexcrichton alexcrichton deleted the alexcrichton:stabilize-1.4 branch Sep 17, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.