Skip to content

Commit eaf81c2

Browse files
committed
miri value visitor: use in macro
1 parent de111e6 commit eaf81c2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/librustc_mir/interpret/visitor.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -125,14 +125,14 @@ impl<'a, 'mir, 'tcx, M: Machine<'a, 'mir, 'tcx>> Value<'a, 'mir, 'tcx, M>
125125
}
126126

127127
macro_rules! make_value_visitor {
128-
($visitor_trait_name:ident, $($mutability:ident)*) => {
128+
($visitor_trait_name:ident, $($mutability:ident)?) => {
129129
// How to traverse a value and what to do when we are at the leaves.
130130
pub trait $visitor_trait_name<'a, 'mir, 'tcx: 'mir+'a, M: Machine<'a, 'mir, 'tcx>>: Sized {
131131
type V: Value<'a, 'mir, 'tcx, M>;
132132

133133
/// The visitor must have an `EvalContext` in it.
134-
fn ecx(&$($mutability)* self)
135-
-> &$($mutability)* EvalContext<'a, 'mir, 'tcx, M>;
134+
fn ecx(&$($mutability)? self)
135+
-> &$($mutability)? EvalContext<'a, 'mir, 'tcx, M>;
136136

137137
// Recursive actions, ready to be overloaded.
138138
/// Visit the given value, dispatching as appropriate to more specialized visitors.

0 commit comments

Comments
 (0)