Always use const param envs for const eval.
Nothing else makes sense, and there is no "danger" in doing so, as it only does something if there are const bounds, which are unstable. This used to happen implicitly via the inferctxt before, which was much more fragile.
This commit is contained in:
parent
a9a79f657c
commit
f394bb57bb
5 changed files with 12 additions and 0 deletions
|
@ -3248,6 +3248,7 @@ impl<'hir> Node<'hir> {
|
|||
Node::Item(Item { kind: ItemKind::Const(..), .. })
|
||||
| Node::Item(Item { kind: ItemKind::Static(..), .. })
|
||||
| Node::TraitItem(TraitItem { kind: TraitItemKind::Const(..), .. })
|
||||
| Node::AnonConst(_)
|
||||
| Node::ImplItem(ImplItem { kind: ImplItemKind::Const(..), .. }) => Constness::Const,
|
||||
|
||||
_ => Constness::NotConst,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue