aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java
diff options
context:
space:
mode:
authorGravatar Nathan Harmata <nharmata@google.com>2015-02-24 01:10:22 +0000
committerGravatar Han-Wen Nienhuys <hanwen@google.com>2015-02-24 01:10:22 +0000
commit8da263cb6275f3822551b4a26544a4b8692199c8 (patch)
tree5a79cbd9499be65e01f8b9b4c0e2069eb71ebc37 /src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java
parentad5e4cec8862c5e2e2c5e4c055e941f11086860f (diff)
Use a factory method in ASTFileLookupValue to enforce that the NO_FILE constant is correctly used.
-- MOS_MIGRATED_REVID=87008436
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java b/src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java
index c10608166c..b318f3ee1f 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/PackageFunction.java
@@ -436,7 +436,7 @@ public class PackageFunction implements SkyFunction {
if (astLookupValue == null) {
return null;
}
- List<Statement> preludeStatements = astLookupValue == ASTFileLookupValue.NO_FILE
+ List<Statement> preludeStatements = astLookupValue.getAST() == null
? ImmutableList.<Statement>of() : astLookupValue.getAST().getStatements();
// Load the BUILD file AST and handle Skylark dependencies. This way BUILD files are