-
-
Notifications
You must be signed in to change notification settings - Fork 21k
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
Make push_error
and push_warning
print name of calling function
#93648
Open
TV4Fun
wants to merge
11
commits into
godotengine:master
Choose a base branch
from
TV4Fun:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+156
−3
Open
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
6955f7b
Allow constructing `List`s from `initializer_list`s
TV4Fun a0a886c
Make `push_error` and `push_warning` print name of calling function
TV4Fun 699c0eb
Fix code style issues
TV4Fun 4c5e93d
Move C++ code line discovery to its own function
TV4Fun cab9969
Move platform dependent code into `OS` class and fix stacktrace from …
TV4Fun 7d42962
Try fix for Linux builds
TV4Fun 07e29f7
Actual fix for Linux builds
TV4Fun 8ac389d
Fix Android and Web builds
TV4Fun 029246d
Remove unnecessary `i == 0` checks from string building loops
TV4Fun 062a924
Revert "Remove unnecessary `i == 0` checks from string building loops"
TV4Fun 0d5a775
Prefix arguments with `p_`
TV4Fun File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -757,6 +757,19 @@ | |
return PREFERRED_TEXTURE_FORMAT_S3TC_BPTC; | ||
} | ||
|
||
#ifdef DEBUG_ENABLED | ||
String OS_MacOS::get_debug_descriptor(const StackInfo &p_info) { | ||
String pipe; | ||
Error error = execute("atos", { "-o", p_info.file, "-l", String::num_uint64(reinterpret_cast<uint64_t>(p_info.load_address), 16), String::num_uint64(reinterpret_cast<uint64_t>(p_info.symbol_address), 16) }, &pipe); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
|
||
if (error == OK) { | ||
return pipe.strip_edges(); | ||
} else { | ||
return String(); | ||
} | ||
} | ||
#endif | ||
|
||
void OS_MacOS::run() { | ||
if (!main_loop) { | ||
return; | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
These should be in the respective OS implementations I'd say, i.e. Mac and Linux, or overridden as stubs in Android and Web, this makes it hard to track
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.
@AThousandShips I think it makes the most sense to keep them in
OS_Unix
becauseexecinfo.h
is theoretically a part of any standards-compliant Unix system. The problem is that Android and Emscripten aren't fully POSIX compliant and don't provide theexecinfo.h
header. I was surprised to even see that they were children ofOS_Unix
because neither are really Unix systems. I can remove the#ifdef
s from the header here, but I will need to keep them inos_unix.cpp
(which already has a ton of these because of the differences in different Unix implementations) because the implementation there depends on being able to importexecinfo.h
, which is not present in eitherThere 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.
Fair enough, but this makes it harder to find as it'd be expected to be in those platforms instead of drivers
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.
Yeah, it's weird to me that
OS_MacOS
inplatform
inherits fromOS_Unix
indrivers
, which inherits fromOS
incore
, and each provides different portions of the platform class's implementation, but here we are.