granite-rust/compiler/rustc_lint/src
Matthias Krüger 72e8fb4268
Rollup merge of #123050 - RalfJung:panic_str, r=m-ou-se
panic_str only exists for the migration to 2021 panic macros

The only caller is `expect_failed`, which is already a cold inline(never) function, so inlining into that function should be fine. (And indeed `panic_str` was `#[inline]` anyway.)

The existence of panic_str risks someone calling it when they should call `panic` instead, and I can't see a reason why this footgun should exist.

I also extended the comment in `panic` to explain why it needs a `'static` string -- I know I've wondered about this in the past and it took me quite a while to understand.
2024-04-23 12:10:25 +02:00
..
context Move --check-cfg documentation to stable books 2024-04-15 21:49:56 +02:00
nonstandard_style mv compiler to compiler/ 2020-08-30 18:45:07 +03:00
array_into_iter.rs Mark some once-again-unreachable paths as unreachable. 2024-02-29 11:08:29 +11:00
async_fn_in_trait.rs Rename TyCtxt::emit_spanned_lint as TyCtxt::emit_node_span_lint. 2024-01-23 08:09:05 +11:00
builtin.rs Deny gen keyword in edition_2024_compat lints 2024-04-22 11:51:50 -04:00
context.rs has_typeck_results doesnt need to be a query 2024-04-17 22:18:27 -04:00
deref_into_dyn_supertrait.rs Auto merge of #120017 - nnethercote:lint-api, r=oli-obk 2024-01-23 00:06:57 +00:00
drop_forget_useless.rs hir: Remove hir::Map::{opt_parent_id,parent_id,get_parent,find_parent} 2024-02-10 12:24:46 +03:00
early.rs Rename {enter,exit}_lint_attrs to check_attributes{,_post} 2024-03-24 14:57:57 +00:00
enum_intrinsics_non_enums.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
errors.rs Rename AddToDiagnostic as Subdiagnostic. 2024-03-11 10:04:49 +11:00
expect.rs Rename TyCtxt::emit_spanned_lint as TyCtxt::emit_node_span_lint. 2024-01-23 08:09:05 +11:00
for_loops_over_fallibles.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
foreign_modules.rs Make RawPtr take Ty and Mutbl separately 2024-03-22 11:13:29 -04:00
hidden_unicode_codepoints.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
internal.rs Allow multiple impl Into<{D,Subd}iagMessage> parameters in a function. 2024-03-11 16:42:10 +11:00
invalid_from_utf8.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
late.rs Avoid lots of hir::HirId{,Map,Set} qualifiers. 2024-04-16 16:29:15 +10:00
let_underscore.rs Rename hir::Local into hir::LetStmt 2024-03-22 20:36:21 +01:00
levels.rs Rename hir::Local into hir::LetStmt 2024-03-22 20:36:21 +01:00
lib.rs Rollup merge of #123680 - compiler-errors:gen-kw, r=Nadrieril 2024-04-23 06:24:55 +02:00
lints.rs Add support for NonNull in ambiguous_wide_ptr_comparisions 2024-03-29 22:02:07 +01:00
map_unit_fn.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
methods.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
multiple_supertrait_upcastable.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
non_ascii_idents.rs Rename all ParseSess variables/fields/lifetimes as psess. 2024-03-05 08:11:45 +11:00
non_fmt_panic.rs panic_str only exists for the migration to 2021 panic macros 2024-03-26 08:11:34 +01:00
non_local_def.rs Auto merge of #123594 - Urgau:fix-non_local_def-lint-overflow, r=lcnr 2024-04-21 17:02:03 +00:00
nonstandard_style.rs Hoist only-executables check above producing crate ident 2024-03-01 19:16:02 +00:00
noop_method_call.rs When encountering <&T as Clone>::clone(x) because T: Clone, suggest #[derive(Clone)] 2024-02-22 18:01:20 +00:00
opaque_hidden_inferred_bound.rs update messages 2024-04-03 19:03:12 -04:00
pass_by_value.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
passes.rs Rename {enter,exit}_lint_attrs to check_attributes{,_post} 2024-03-24 14:57:57 +00:00
ptr_nulls.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
redundant_semicolon.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
reference_casting.rs Make RawPtr take Ty and Mutbl separately 2024-03-22 11:13:29 -04:00
tests.rs refactor(rustc_lint): inline check_lint_name_cmdline 2023-08-30 17:35:07 +01:00
traits.rs Rename LintContext::emit_spanned_lint as LintContext::emit_span_lint. 2024-01-23 08:08:25 +11:00
types.rs Actually create ranged int types in the type system. 2024-04-08 12:02:19 +00:00
unit_bindings.rs Rename hir::Local into hir::LetStmt 2024-03-22 20:36:21 +01:00
unused.rs Rename BindingAnnotation to BindingMode 2024-04-17 09:34:39 -04:00