-
Notifications
You must be signed in to change notification settings - Fork 617
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
[wpiutil] Use C++23 stacktrace library on Windows #6839
base: main
Are you sure you want to change the base?
[wpiutil] Use C++23 stacktrace library on Windows #6839
Conversation
shared/config.gradle
Outdated
// Use C++23 on Windows | ||
nativeUtils.platformConfigs.each { | ||
if (it.name.contains('windows')) { | ||
it.cppCompiler.args.add("/std:c++latest") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm. This might be a problem. I'm not sure if mixing /std:c++latest and /std:c++20 is safe, and team programs would still be c++ 20. c++latest technically isn't ABI safe across runtime releases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what I've read, /std:c++latest
isn't guaranteed to have stable standard support. MSVC doesn't have a /std:c++23
flag yet either, tho they've had std::stacktrace support since VS 17.4 (released November 2022).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me see if theres a way in gradle to just set that one file to c++latest, at least for the gradle build. I'd prefer limiting the scope as much as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it need to be set to c++latest to use std::stacktrace?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ad760b0
to
0141b53
Compare
5fbd5b0
to
d09856e
Compare
d09856e
to
757c762
Compare
757c762
to
0152995
Compare
453c595
to
98b7368
Compare
98b7368
to
5afec7c
Compare
5afec7c
to
ef97f6e
Compare
Honestly, until MSVC gets a /std:c++23 flag, this really can't be merged. We cannot ship libraries targeting /std:c++latest safely at all. |
ef97f6e
to
20c9dbb
Compare
20c9dbb
to
2be6142
Compare
2be6142
to
d006b67
Compare
While we're waiting for the C++23 final version to land in MSVC, if StackWalker is non-functional, we can just remove it in the meantime (and just return an empty string). |
d006b67
to
6e212ff
Compare
Here's the StackWalker removal PR: #7777 |
abbc631
to
876d410
Compare
876d410
to
b196da0
Compare
This lets us remove the unmaintained StackWalker library and its hacky upstream_utils script.
@Gold856 reported that StackWalker gives blank stacktraces: https://discord.com/channels/176186766946992128/368993897495527424/1261940029287301150. They also reported an earlier version of this PR giving the following stacktrace instead: