-
Notifications
You must be signed in to change notification settings - Fork 10.6k
[NFC][Diagnostics]: remove a number of unused diagnostics #85282
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
Conversation
|
@swift-ci please smoke test |
| NOTE(scanner_cycle_source_target_shadow_module, none, | ||
| "source target '%0' shadowing a%select{ |n SDK }2Swift module with the same name at: '%1'", (StringRef, StringRef, bool)) | ||
|
|
||
| ERROR(scanner_arguments_invalid, none, |
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.
last use: 41e4712
| "unknown library level '%0', " | ||
| "expected one of 'api', 'spi', 'ipi', or 'other'", (StringRef)) | ||
|
|
||
| ERROR(error_old_spi_only_import_unsupported, none, |
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.
last use: 9e93b7b
| ERROR(error_create_symbolic_interfaces_dir,none, | ||
| "creating symbolic interfaces directory: %0", (StringRef)) | ||
| ERROR(error_symbolic_interfaces_failed_status_check,none, | ||
| "failed file status check: %0", (StringRef)) | ||
| ERROR(error_write_symbolic_interface,none, | ||
| "writing symbolic interface file: %0", (StringRef)) | ||
| REMARK(remark_emitting_symbolic_interface_module,none, |
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.
last uses: b51cfa5
| ERROR(error_formatting_multiple_file_ranges,none, | ||
| "file ranges don't support multiple input files", ()) | ||
|
|
||
| ERROR(error_formatting_invalid_range,none, | ||
| "file range is invalid", ()) |
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.
last use: 6443619
| // Caching related diagnostics | ||
| GROUPED_ERROR(error_caching_no_cas_fs, CompilationCaching, none, | ||
| "caching is enabled without CAS file-system options, input is not immutable", ()) | ||
| ERROR(error_prefix_mapping, none, "cannot create scanner prefix mapping: '%0'", (StringRef)) |
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.
last use: 0384347
- TODO: verify removal – cc @sina-mahdavi could you confirm whether it is expected that this is unused please?
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.
edit: looks like the error was introduced here, but the error handling function it was for (llvm::MappedPrefix::transformJoined) is no longer used, so seems reasonable to remove.
| "transitive dependency on '%0'", | ||
| (StringRef, Identifier, unsigned)) | ||
|
|
||
| REMARK(explicit_interface_build_skipped,none, |
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.
last use: 4cdbcb8
- TODO: verify removal
| "protocol %0 can not yet be represented in C++", (ValueDecl *)) | ||
| ERROR(expose_move_only_to_cxx,none, | ||
| "noncopyable %kind0 can not yet be represented in C++", (ValueDecl *)) | ||
| ERROR(expose_nested_type_to_cxx,none, |
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.
last use: 8603dfe
| "actor boundary", | ||
| (Type, const ValueDecl *, ActorIsolation)) | ||
|
|
||
| ERROR(non_sendable_call_result_type,none, |
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.
last use: cff835e
| ERROR(invalid_ownership_not_optional,none, | ||
| "%0 variable should have optional type %1", | ||
| (ReferenceOwnership, Type)) | ||
| ERROR(invalid_ownership_is_let,none, |
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.
last use: 89f8f8b
- TODO: verify removal – cc @nickolas-pohilets i see this was recently(ish) removed for the 'weak let' feature, rather than becoming conditional on the presence of that feature itself; is that expected/intentional?
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.
edit: upon further inspection, i think this was the desired behavior – weak let is now unconditionally supported, but the mutability of weak captures is the thing controlled via the upcoming feature flag. thus, the error is no longer applicable. do correct me if i'm mistaken.
| none, "'@_noImplicitCopy' attribute can only be applied to local lets and params", ()) | ||
| ERROR(noimplicitcopy_attr_not_allowed_on_moveonlytype,none, | ||
| "'@_noImplicitCopy' has no effect when applied to a noncopyable type", ()) | ||
| ERROR(noncopyable_types_cannot_be_resilient, none, |
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.
|
@swift-ci please clean smoke test macos |
artemcm
left a comment
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.
Very nice, thank you.
|
@artemcm thank you for the review! i've now convinced myself all of these seem reasonable to remove – idk what the protocol is for merging something like this, though i'd prefer it be merged sooner rather than later to reduce the likelihood of conflicts if possible. if that seems alright to you, please merge at your convenience. 🙇 |
did a pass through the diagnostics to identify potentially-unused ones. criteria for inclusion was roughly: