diff --git a/src/driver/driver_api.cc b/src/driver/driver_api.cc index 17ab38ed450f2..ad1f51ba6d714 100644 --- a/src/driver/driver_api.cc +++ b/src/driver/driver_api.cc @@ -166,7 +166,7 @@ transform::Pass BindTarget(Target target) { } static transform::Pass AnnotateEntryFunc(bool b) { - auto fpass = [b](tir::PrimFunc f, IRModule m, transform::PassContext ctx) { + auto fpass = [](tir::PrimFunc f, IRModule m, transform::PassContext ctx) { return WithAttr(std::move(f), tir::attr::kIsEntryFunc, Bool(true)); }; return tir::transform::CreatePrimFuncPass(fpass, 0, "AnnotateEntryFunc", {}); diff --git a/src/relay/backend/vm/compiler.cc b/src/relay/backend/vm/compiler.cc index c4c50c6c5646d..02477d05673b8 100644 --- a/src/relay/backend/vm/compiler.cc +++ b/src/relay/backend/vm/compiler.cc @@ -618,8 +618,7 @@ class VMFunctionCompiler : DeviceAwareExprFunctor { } }) .Match("memory.alloc_storage", - [this, call_node](const Array& args, const Attrs& attrs, - const Array& type_arg) { + [this](const Array& args, const Attrs& attrs, const Array& type_arg) { ICHECK_EQ(args.size(), 2); // Compute the size of the allocation. this->VisitExpr(args[0]);