Skip to content

Migrate parts of the stdlib to UnsafeRawPointer. #3792

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 5 commits into from
Jul 27, 2016
Merged

Migrate parts of the stdlib to UnsafeRawPointer. #3792

merged 5 commits into from
Jul 27, 2016

Conversation

atrick
Copy link
Contributor

@atrick atrick commented Jul 27, 2016

Required for SE-0107: UnsafeRawPointer.

This is necessary to implement the proposed UnsafePointer initializers.

Lots of changes to StringCore here.

@atrick
Copy link
Contributor Author

atrick commented Jul 27, 2016

@swift-ci Please smoke test.

@atrick
Copy link
Contributor Author

atrick commented Jul 27, 2016

@swift-ci Please smoke test and merge.

atrick added 5 commits July 27, 2016 08:05
…ray.

In order to conform to the memory model.
This is another necessary step in introducing changes
for SE-0107: UnsafeRawPointer.

UnsafeRawPointer is great for bytewise pointer operations.

OpaquePointer goes away.

The _RawByte type goes away.

StringBuffer always binds memory to the correct CodeUnit
when allocating memory.

Before accessing the string, a dynamic element width check
allows us to assume the bound memory type.

Generic entry points like atomicCompareExchange no longer handle
both kinds of pointers. Normally that's good because you
should not be using generics in that case, just upcast
to raw pointer. However, with pointers-to-pointers
you can't do that.
@atrick
Copy link
Contributor Author

atrick commented Jul 27, 2016

@swift-ci Please smoke test and merge.

@swift-ci swift-ci merged commit dfc3933 into swiftlang:master Jul 27, 2016
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.

2 participants