-
Notifications
You must be signed in to change notification settings - Fork 575
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix handling of printing caller with Write, Print, and Printf. (#315)
* Add event.CallerSkipFrame(skip int) This indicates that, for this event, we should skip an additional specified number of frames. This is cumulative, calling it twice for the same event will add both numbers together, and this is in addition to any skip frame settings set through the context, or globally. The indended purpose is for wrappers to Msg or Msgf, so that the actual caller is always printed correctly. * Use CallerSkipFrame for Print, Printf, and Write. This allows us to use the correct caller when using these 3 functions. Co-authored-by: Zephaniah E. Loss-Cutler-Hull <warp@aehallh.com>
- Loading branch information
Showing
3 changed files
with
22 additions
and
12 deletions.
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