Merge "Default to pattern initialization for uninitialized variables (try 2)."

This commit is contained in:
Treehugger Robot 2020-01-31 21:52:44 +00:00 committed by Gerrit Code Review
commit d35fcae5dc
1 changed files with 3 additions and 0 deletions

View File

@ -168,6 +168,9 @@ func init() {
flags = append(flags, "-ftrivial-auto-var-init=pattern")
} else if ctx.Config().IsEnvTrue("AUTO_UNINITIALIZE") {
flags = append(flags, "-ftrivial-auto-var-init=uninitialized")
} else {
// Default to pattern initialization.
flags = append(flags, "-ftrivial-auto-var-init=pattern")
}
return strings.Join(flags, " ")