Skip to content

Add overloads to WriteVerbose/WriteWarning to defer string construction until it's necessary #6740

@daxian-dbw

Description

@daxian-dbw

Quote from Jason's comment in #6708:

Not for this PR - but the result of this format call is typically thrown away. It should be possible to check if methods like WriteVerbose will do anything before formatting, or at least add overloads that do the formatting only after deciding the formatted string is needed.

We could add a few overloads to WriteVerbose and WriteWarning, which take a format string and arguments. So we can defer the construction of message until we know for sure we are going to write out verbose messages.

Open this issue to track this investigation.

Metadata

Metadata

Assignees

Labels

In-PRIndicates that a PR is out for the issueIssue-Code Cleanupthe issue is for cleaning up the code with no impact on functionalityResolution-No ActivityIssue has had no activity for 6 months or more

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions