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

Avoid unnecessarily allocating an array when initializing String from a sequence of bytes #4813

Merged
merged 1 commit into from
Jan 4, 2024

Conversation

fumoboy007
Copy link
Contributor

@fumoboy007 fumoboy007 commented Aug 28, 2023

No description provided.

@fumoboy007
Copy link
Contributor Author

Will these changes automatically make it into the Darwin implementation once merged or do we need to create an Apple feedback report for that?

@parkera
Copy link
Member

parkera commented Aug 28, 2023

The Darwin implementation (and future everywhere implementation) is over here: https://github.com/apple/swift-foundation/blob/main/Sources/FoundationEssentials/String/String%2BEssentials.swift#L86

@fumoboy007
Copy link
Contributor Author

Oh nice, it already has this optimization!

@fumoboy007
Copy link
Contributor Author

@parkera Should we merge this?

@parkera
Copy link
Member

parkera commented Sep 5, 2023

@swift-ci test

@fumoboy007
Copy link
Contributor Author

The macOS issue seems to be

CMake Error at CMakeLists.txt:11 (project):
  The CMAKE_C_COMPILER:

    /Users/ec2-user/jenkins/workspace/swift-corelibs-foundation-PR-macOS/branch-main/build/Ninja-ReleaseAssert/toolchain-macosx-x86_64/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang

  is not a full path to an existing compiler tool.

  Tell CMake where to find the compiler by setting either the environment
  variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to
  the compiler, or to the compiler name if it is in the PATH.

@MaxDesiatov
Copy link
Member

@swift-ci test macos

@fumoboy007
Copy link
Contributor Author

All checks passed!

@fumoboy007
Copy link
Contributor Author

Happy New Year! Please review. 🙏

@parkera parkera merged commit c854cfc into apple:main Jan 4, 2024
3 checks passed
@fumoboy007 fumoboy007 deleted the patch-1 branch January 4, 2024 00: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.

3 participants