File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -346,10 +346,14 @@ struct CmdFlakeCheck : FlakeCommand
346346 auto checkOverlay = [&](const std::string & attrPath, Value & v, const Pos & pos) {
347347 try {
348348 state->forceValue (v, pos);
349- if (!v.isLambda () || v.lambda .fun ->hasFormals () || std::string (v.lambda .fun ->arg ) != " final" )
349+ if (!v.isLambda () || v.lambda .fun ->hasFormals () ||
350+ (std::string (v.lambda .fun ->arg ) != " final" &&
351+ std::string (v.lambda .fun ->arg ) != " _final" ))
350352 throw Error (" overlay does not take an argument named 'final'" );
351353 auto body = dynamic_cast <ExprLambda *>(v.lambda .fun ->body );
352- if (!body || body->hasFormals () || std::string (body->arg ) != " prev" )
354+ if (!body || body->hasFormals () ||
355+ (std::string (body->arg ) != " prev" &&
356+ std::string (body->arg ) != " _prev" ))
353357 throw Error (" overlay does not take an argument named 'prev'" );
354358 // FIXME: if we have a 'nixpkgs' input, use it to
355359 // evaluate the overlay.
You can’t perform that action at this time.
0 commit comments