Skip to content

std: Update CString::{into,from}_raw with *mut T #28198

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

Merged
merged 1 commit into from
Sep 9, 2015

Conversation

alexcrichton
Copy link
Member

Conventionally in C *mut T is a transfer of ownership where *const T is a
loan, so *mut T is likely the more appropriate return type for these
functions. Additionally, this more closely mirrors the APIs on Box for this
sort of functionality.

cc #27769

Conventionally in C `*mut T` is a transfer of ownership where `*const T` is a
loan, so `*mut T` is likely the more appropriate return type for these
functions. Additionally, this more closely mirrors the APIs on `Box` for this
sort of functionality.

cc rust-lang#27769
@rust-highfive
Copy link
Contributor

r? @pcwalton

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

@alexcrichton
Copy link
Member Author

r? @aturon

@rust-highfive rust-highfive assigned aturon and unassigned pcwalton Sep 3, 2015
@aturon
Copy link
Member

aturon commented Sep 8, 2015

@bors: r+

@bors
Copy link
Collaborator

bors commented Sep 8, 2015

📌 Commit 6bb2c5d has been approved by aturon

bors added a commit that referenced this pull request Sep 9, 2015
Conventionally in C `*mut T` is a transfer of ownership where `*const T` is a
loan, so `*mut T` is likely the more appropriate return type for these
functions. Additionally, this more closely mirrors the APIs on `Box` for this
sort of functionality.

cc #27769
@bors
Copy link
Collaborator

bors commented Sep 9, 2015

⌛ Testing commit 6bb2c5d with merge 44e6573...

@bors bors merged commit 6bb2c5d into rust-lang:master Sep 9, 2015
@alexcrichton alexcrichton deleted the from-raw-mut branch October 21, 2015 06:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants