Skip to content

Building stdlib/public/Backtracing/Backtrace.swift fails #66457

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

Closed
AnthonyLatsis opened this issue Jun 8, 2023 · 5 comments · Fixed by #66449 or #66485
Closed

Building stdlib/public/Backtracing/Backtrace.swift fails #66457

AnthonyLatsis opened this issue Jun 8, 2023 · 5 comments · Fixed by #66449 or #66485
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. build-script Area → utils: The build script swift 5.9 unexpected error Bug: Unexpected error utils Area: the build system and other accessory scripts under the "utils" directory

Comments

@AnthonyLatsis
Copy link
Collaborator

Description

Command:

utils/build-script --skip-build-benchmarks --skip-ios --skip-watchos --skip-tvos --swift-darwin-supported-archs="$(uname -m)" --release-debuginfo --sccache --swift-disable-dead-stripping --skip-early-swift-driver --bootstrapping=off

Error:

/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:479:21: error: expected a macro identifier for a pound literal expression
    let mapRegex = #/
                    ^
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:479:21: error: consecutive statements on a line must be separated by ';'
    let mapRegex = #/
                    ^
                    ;
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:479:21: error: operator with postfix spacing cannot start a subexpression
    let mapRegex = #/
                    ^
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:480:49: error: consecutive statements on a line must be separated by ';'
    ^(?<start>[A-Fa-f0-9]+)-(?<end>[A-Fa-f0-9]+)\s+
                                                ^
                                                ;
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:481:22: error: expected ',' separator
    (?<perms>[-rwxsp]{4})\s+
                     ^
                     ,
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:481:26: error: consecutive statements on a line must be separated by ';'
    (?<perms>[-rwxsp]{4})\s+
                         ^
                         ;
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:482:28: error: consecutive statements on a line must be separated by ';'
    (?<offset>[A-Fa-f0-9]+)\s+
                           ^
                           ;
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:483:27: error: consecutive statements on a line must be separated by ';'
    (?<major>[A-Fa-f0-9]+):(?<minor>[A-Fa-f0-9]+)\s+
                          ^
                          ;
/Users/mac/Desktop/swift-project/swift/stdlib/public/Backtracing/Backtrace.swift:483:27: error: expected expression
    (?<major>[A-Fa-f0-9]+):(?<minor>[A-Fa-f0-9]+)\s+
                          ^

Environment

  • Swift version 5.9-dev (LLVM d638e0929fa87b0, Swift 23e2f34)
@AnthonyLatsis AnthonyLatsis added bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. build-script Area → utils: The build script utils Area: the build system and other accessory scripts under the "utils" directory swift 5.9 unexpected error Bug: Unexpected error labels Jun 8, 2023
@AnthonyLatsis
Copy link
Collaborator Author

AnthonyLatsis commented Jun 8, 2023

It seems like --bootstrapping=off is no longer a valid option (or it should cause building of the Backtracing module to be skipped if possible).

@tbkka
Copy link
Contributor

tbkka commented Jun 8, 2023

@al45tair is working on a fix for this. The Backtracing module doesn't technically need to use a regex here.

@al45tair
Copy link
Contributor

al45tair commented Jun 9, 2023

That's in #66449, FWIW. I hadn't appreciated when I wrote that code that it would cause this problem, but it's easy to fix.

@al45tair
Copy link
Contributor

al45tair commented Jun 9, 2023

Should be fixed on main. I'll cherry pick the fix to 5.9 as well.

@al45tair
Copy link
Contributor

al45tair commented Jun 9, 2023

Cherry pick to 5.9 is #66485.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. build-script Area → utils: The build script swift 5.9 unexpected error Bug: Unexpected error utils Area: the build system and other accessory scripts under the "utils" directory
Projects
None yet
3 participants