Skip to content

Commit 06bb1c2

Browse files
committed
Remove some buildMode default parameters
Force the internals to be more explicit.
1 parent 2ee4197 commit 06bb1c2

File tree

4 files changed

+8
-16
lines changed

4 files changed

+8
-16
lines changed

src/libstore/include/nix/store/build/derivation-building-goal.hh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,7 @@ typedef enum { rpAccept, rpDecline, rpPostpone } HookReply;
2929
*/
3030
struct DerivationBuildingGoal : public Goal
3131
{
32-
DerivationBuildingGoal(
33-
const StorePath & drvPath, const Derivation & drv, Worker & worker, BuildMode buildMode = bmNormal);
32+
DerivationBuildingGoal(const StorePath & drvPath, const Derivation & drv, Worker & worker, BuildMode buildMode);
3433
~DerivationBuildingGoal();
3534

3635
private:

src/libstore/include/nix/store/build/derivation-goal.hh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ struct DerivationGoal : public Goal
4545
const Derivation & drv,
4646
const OutputName & wantedOutput,
4747
Worker & worker,
48-
BuildMode buildMode = bmNormal);
48+
BuildMode buildMode);
4949
~DerivationGoal() = default;
5050

5151
void timedOut(Error && ex) override

src/libstore/include/nix/store/build/derivation-resolution-goal.hh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,7 @@ struct BuilderFailureError;
3535
*/
3636
struct DerivationResolutionGoal : public Goal
3737
{
38-
DerivationResolutionGoal(
39-
const StorePath & drvPath, const Derivation & drv, Worker & worker, BuildMode buildMode = bmNormal);
38+
DerivationResolutionGoal(const StorePath & drvPath, const Derivation & drv, Worker & worker, BuildMode buildMode);
4039

4140
/**
4241
* If the derivation needed to be resolved, this is resulting

src/libstore/include/nix/store/build/worker.hh

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -210,32 +210,26 @@ private:
210210
std::shared_ptr<G> initGoalIfNeeded(std::weak_ptr<G> & goal_weak, Args &&... args);
211211

212212
std::shared_ptr<DerivationTrampolineGoal> makeDerivationTrampolineGoal(
213-
ref<const SingleDerivedPath> drvReq, const OutputsSpec & wantedOutputs, BuildMode buildMode = bmNormal);
213+
ref<const SingleDerivedPath> drvReq, const OutputsSpec & wantedOutputs, BuildMode buildMode);
214214

215215
public:
216216
std::shared_ptr<DerivationTrampolineGoal> makeDerivationTrampolineGoal(
217-
const StorePath & drvPath,
218-
const OutputsSpec & wantedOutputs,
219-
const Derivation & drv,
220-
BuildMode buildMode = bmNormal);
217+
const StorePath & drvPath, const OutputsSpec & wantedOutputs, const Derivation & drv, BuildMode buildMode);
221218

222219
std::shared_ptr<DerivationGoal> makeDerivationGoal(
223-
const StorePath & drvPath,
224-
const Derivation & drv,
225-
const OutputName & wantedOutput,
226-
BuildMode buildMode = bmNormal);
220+
const StorePath & drvPath, const Derivation & drv, const OutputName & wantedOutput, BuildMode buildMode);
227221

228222
/**
229223
* @ref DerivationResolutionGoal "derivation resolution goal"
230224
*/
231225
std::shared_ptr<DerivationResolutionGoal>
232-
makeDerivationResolutionGoal(const StorePath & drvPath, const Derivation & drv, BuildMode buildMode = bmNormal);
226+
makeDerivationResolutionGoal(const StorePath & drvPath, const Derivation & drv, BuildMode buildMode);
233227

234228
/**
235229
* @ref DerivationBuildingGoal "derivation building goal"
236230
*/
237231
std::shared_ptr<DerivationBuildingGoal>
238-
makeDerivationBuildingGoal(const StorePath & drvPath, const Derivation & drv, BuildMode buildMode = bmNormal);
232+
makeDerivationBuildingGoal(const StorePath & drvPath, const Derivation & drv, BuildMode buildMode);
239233

240234
/**
241235
* @ref PathSubstitutionGoal "substitution goal"

0 commit comments

Comments
 (0)