Bug fix. Correctly identify expressions using &=, ^=, >>=, and <<= as assignment statements when parsing BUILD files. (#1357)

* Add files via upload

Correctly include &=, ^=, >>=, <<= as assignment statements when parsing BUILD files.

The Starlark grammar reference (https://github.com/bazelbuild/starlark/blob/master/spec.md#grammar-reference) identifies all of these as assignment statements, but the parser doesn't include them in the list, probably an old oversight.

This fixes issue #1330.

* Update warn_control_flow_test

This change adds no-effect tests for &=, ^=, >>=, and <<= to ensure they are recognized as having an effect.
3 files changed
tree: 83668666cdc8766f7cb95e777c2df37ec99c8d0e
  1. .bazelci/
  2. api_proto/
  3. build/
  4. build_proto/
  5. buildifier/
  6. buildozer/
  7. bzlenv/
  8. config/
  9. convertast/
  10. deps_proto/
  11. differ/
  12. edit/
  13. extra_actions_base_proto/
  14. file/
  15. generatetables/
  16. labels/
  17. lang/
  18. release/
  19. tables/
  20. testutils/
  21. unused_deps/
  22. warn/
  23. wspace/
  24. .bazelrc
  25. .gitignore
  26. .mailmap
  27. .pre-commit-config.yaml
  28. BUILD.bazel
  29. CODEOWNERS
  30. CONTRIBUTING.md
  31. CONTRIBUTORS
  32. go.mod
  33. go.sum
  34. launcher.js
  35. LICENSE
  36. MODULE.bazel
  37. README.md
  38. status.py
  39. update_generated.sh
  40. WARNINGS.md
  41. WORKSPACE
  42. WORKSPACE.bzlmod
README.md

Buildtools for bazel

This repository contains developer tools for working with Google's bazel buildtool.

Build status

Setup

See instructions in each tool's directory.