Add back accidentally removed API#152
Merged
Merged
Conversation
Motivation: - When `source:` was added in apple#135, the API was accidentally broken despite source compatability. Modifications: - Add back source-less API calls which defer to the decls with source. - Note we can't deprecate the calls we're adding back: `log.info("some message")` refers to the implementation we're adding back rather and would therefore require users to explicitly specify a source to suppress the deprecation warning message. Result: - API is no longer broken.
glbrntt
force-pushed
the
gb-unbreak-api
branch
from
August 13, 2020 14:54
a36d5cf to
1815fd0
Compare
Contributor
Author
|
API breakages between 1.2.0 and 1.3.0: |
Contributor
Author
|
API breakages between 1.2.0 and this PR: |
Contributor
Author
|
I think these two are okay because of the default implementation on the And this one is also fine for the same reason: it has a default implementation: |
glbrntt
commented
Aug 13, 2020
|
|
||
| extension Logger { | ||
| public func error(_ error: Error, | ||
| public func error(error: Error, |
Contributor
Author
There was a problem hiding this comment.
fyi: I had to rename this so let error = logger.error(_:metadata:file:function:line:) wasn't ambiguous
ktoso
self-requested a review
August 13, 2020 15:06
Member
|
(Sorry for being slow to get to this, will do soon -- want to make sure it's really correct this time) |
Contributor
Author
No worries; I'm in no rush for this! |
ktoso
approved these changes
Feb 22, 2021
ktoso
left a comment
Member
There was a problem hiding this comment.
Oh my, I was pretty bad to follow up here but LGTM.
Going to release with this today
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Motivation:
source:was added in add source for log messages #135, the API was accidentally brokendespite source compatability.
Modifications:
log.info("some message")refers to the implementation we're addingback rather and would therefore require users to explicitly specify a source
to suppress the deprecation warning message.
Result: