Use bug!
instead of panic!
Co-authored-by: varkor <github@varkor.com>
This commit is contained in:
parent
718d28cf85
commit
fd76d236e4
@ -489,7 +489,9 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
|
||||
"lifetime" => ParamKindOrd::Lifetime,
|
||||
"type" => ParamKindOrd::Type,
|
||||
"constant" => ParamKindOrd::Const,
|
||||
_ => panic!(),
|
||||
// It's more concise to match on the string representation, though it means
|
||||
// the match is non-exhaustive.
|
||||
_ => bug!("invalid generic parameter kind"),
|
||||
};
|
||||
let arg_ord = match arg {
|
||||
GenericArg::Lifetime(_) => ParamKindOrd::Lifetime,
|
||||
|
Loading…
Reference in New Issue
Block a user