[SR-7349] Bad diagnostic using internal generic argument in superclass #49897
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
diagnostics QoI
Bug: Diagnostics Quality of Implementation
Environment
Xcode Version 9.4 beta (9Q1004a)
Additional Detail from JIRA
md5: 05fc683074114c7b22e3729aeb958c63
Issue Description:
This little code snippet will trigger a warning underlining `B`. Obviously, there shouldn't be a problem here as long as all occurrences of `Foo` in `A` are at least internal (or stricter). Otherwise, they are simply downgraded to the same access level as the type that is involved.
Thread
I understand this is simply a warning, but I think it is understandable they can be annoying when appearing in hundreds from pods and external frameworks without a significant reason. I would like to request not to show this warning unless it bears important information (i.e. that can lead to unsafe code.) or if the code doesn't involve any access level downgrading because of the inheritance, like in my case.
In contrast, a case that deserves a warning or even an error (warning if
t
andinit
aren't explicitly public, otherwise error)The text was updated successfully, but these errors were encountered: