GN args default values should take into account the default_args in the dotfile |
||
Issue descriptionThe .gn file can now declare default_args which override declare_args defaults. This isn't accounted for when giving the default value of an arg in the tool which is confusing.
,
Jan 25 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/9257ae440105ca90bd219517782cf55258fc830c commit 9257ae440105ca90bd219517782cf55258fc830c Author: brettw <brettw@chromium.org> Date: Wed Jan 25 00:49:55 2017 Display override values in GN args help. Previously "gn args --list" would display the default value only. Now that we have default_args in the .gn file, there are more places for the values to come from and this is confusing (because the default value isn't necessarily what you get). This change makes --list display both the current value and the default value, and the locations of the definitions for each. So when default_args apply, you can see where the value is set. The same applies to args set in the args.gn file for a build. It looks like this: is_debug Current value = false From //.gn:15 Overridden from the default = true From //build/config/BUILDCONFIG.gn:154 The short mode --list --short has changed to list the current value rather than the default. Some obsolete help text was updated and some unused Args functions were removed. BUG= 684169 , 416139 Review-Url: https://codereview.chromium.org/2651023004 Cr-Commit-Position: refs/heads/master@{#445883} [modify] https://crrev.com/9257ae440105ca90bd219517782cf55258fc830c/tools/gn/args.cc [modify] https://crrev.com/9257ae440105ca90bd219517782cf55258fc830c/tools/gn/args.h [modify] https://crrev.com/9257ae440105ca90bd219517782cf55258fc830c/tools/gn/command_args.cc
,
Jan 25 2017
|
||
►
Sign in to add a comment |
||
Comment 1 by brettw@chromium.org
, Jan 24 2017Status: Started (was: Available)