mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 16:23:02 +00:00
parseDerivation(): Fix warning about uninitialized 'version' variable
This commit is contained in:
parent
e9a857e418
commit
55dd1244d2
@ -352,7 +352,7 @@ Derivation parseDerivation(
|
||||
expect(str, "erive(");
|
||||
version = DerivationATermVersion::Traditional;
|
||||
break;
|
||||
case 'r':
|
||||
case 'r': {
|
||||
expect(str, "rvWithVersion(");
|
||||
auto versionS = parseString(str);
|
||||
if (versionS == "xp-dyn-drv") {
|
||||
@ -365,6 +365,9 @@ Derivation parseDerivation(
|
||||
expect(str, ",");
|
||||
break;
|
||||
}
|
||||
default:
|
||||
throw Error("derivation does not start with 'Derive' or 'DrvWithVersion'");
|
||||
}
|
||||
|
||||
/* Parse the list of outputs. */
|
||||
expect(str, "[");
|
||||
|
Loading…
Reference in New Issue
Block a user