Skip to content

Commit fbda05e

Browse files
committed
Refer to the platform "extra_flags" properties in a less confusing manner
There is a convention of configuring Arduino boards platforms to provide a user interface for configuring the build process through the addition of references and fallback empty definitions of a series of properties that follow the format of `compiler.<pattern type>.extra_flags`, where "<pattern type>" corresponds to the compilation pattern that references them: - `c` - `cpp` - `S` - `ar` - `c.elf` Previously, `x` was used as a placeholder for the component of the property name that varies in order to allow a single rule to refer to the entire set. "<pattern type>" is a little bit more clear than "x".
1 parent f62a372 commit fbda05e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Diff for: internal/rule/ruleconfiguration/ruleconfiguration.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -1696,8 +1696,8 @@ var configurations = []Type{
16961696
Category: "configuration files",
16971697
Subcategory: "boards.txt",
16981698
ID: "PF009",
1699-
Brief: "use of compiler.x.extra_flags",
1700-
MessageTemplate: "Board ID(s) {{.}} use compiler.x.extra_flags properties. These are intended to be left for use by the user.",
1699+
Brief: "use of compiler.<pattern type>.extra_flags",
1700+
MessageTemplate: "Board ID(s) {{.}} use compiler.<pattern type>.extra_flags properties. These are intended to be left for use by the user.",
17011701
Description: "A board definition in the platform's `boards.txt` configuration file is using one of the `compiler.<pattern type>.extra_flags` properties (e.g., `compiler.cpp.extra_flags`). These are intended to be left for use by the user as a standardized interface for customizing the compilation commands. The platform author can define as many arbitrary properties as they like, so there is no need for them to take the user's properties.",
17021702
Reference: "",
17031703
DisableModes: nil,

Diff for: internal/rule/rulefunction/platform.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ func BoardsTxtBoardIDBuildCoreLTMinLength() (result ruleresult.Type, output stri
169169
return ruleresult.Pass, ""
170170
}
171171

172-
// BoardsTxtUserExtraFlagsUsage checks if the user's compiler.x.extra_flags properties are used in boards.txt.
172+
// BoardsTxtUserExtraFlagsUsage checks if the user's compiler.<pattern type>.extra_flags properties are used in boards.txt.
173173
func BoardsTxtUserExtraFlagsUsage() (result ruleresult.Type, output string) {
174174
if projectdata.BoardsTxtLoadError() != nil {
175175
return ruleresult.NotRun, "Couldn't load boards.txt"

0 commit comments

Comments
 (0)