Skip to content

Commit

Permalink
Flip the --incompatible_disallow_native_in_build_file flag
Browse files Browse the repository at this point in the history
Fixes #7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_file=false as a flag to Blaze.

PiperOrigin-RevId: 249508813
  • Loading branch information
vladmos authored and copybara-github committed May 22, 2019
1 parent 82df64d commit 8241d27
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ public class StarlarkSemanticsOptions extends OptionsBase implements Serializabl

@Option(
name = "incompatible_disallow_native_in_build_file",
defaultValue = "false",
defaultValue = "true",
documentationCategory = OptionDocumentationCategory.STARLARK_SEMANTICS,
effectTags = {OptionEffectTag.BUILD_FILE_SEMANTICS},
metadataTags = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ public static Builder builderWithDefaults() {
.incompatibleDisallowLegacyJavaProvider(false)
.incompatibleDisallowLegacyJavaInfo(false)
.incompatibleDisallowLoadLabelsToCrossPackageBoundaries(true)
.incompatibleDisallowNativeInBuildFile(false)
.incompatibleDisallowNativeInBuildFile(true)
.incompatibleDisallowOldOctalNotation(true)
.incompatibleDisallowOldStyleArgsAdd(true)
.incompatibleDisallowRuleExecutionPlatformConstraintsAllowed(false)
Expand Down
2 changes: 1 addition & 1 deletion src/test/shell/bazel/local_repository_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -904,7 +904,7 @@ genrule(
name = 'b',
srcs = [],
outs = ['bo'],
cmd = 'echo ' + native.repository_name() + ' ' + native.package_name() + ' > $@')
cmd = 'echo ' + repository_name() + ' ' + package_name() + ' > $@')
EOF

cat > WORKSPACE <<EOF
Expand Down

0 comments on commit 8241d27

Please sign in to comment.