Skip to content

Toolchain names should be given numeric prefixes for clear ordering #3

@rickeylev

Description

@rickeylev

When Bazel expands wildcards in e.g. register_toolchain("//foo/..."), it sorts the found targets lexicographical. Because the order toolchains are checked matters (the first matching wins), it's best practice to give toolchains a zero-padded numeric prefix to ensure this subtle detail is explicit and that their names can be load-bearing (generally the sort order of target names doesn't matter).

So, the toolchain() targets in cc_toolchain/BUILD.bazel should each be given a zero-padded numeric prefix.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions