OSDN Git Service

[yaml2obj] - Add a way to set default values for macros used in a YAML.
authorGeorgii Rymar <grimar@accesssoftek.com>
Wed, 24 Jun 2020 12:18:53 +0000 (15:18 +0300)
committerGeorgii Rymar <grimar@accesssoftek.com>
Tue, 30 Jun 2020 09:05:30 +0000 (12:05 +0300)
commit657c4ab39dc80f569f422d40347b97586c27b2ba
tree2f4df551a86fbba7a334f995ea7e282761306441
parentd7173826331eb2c263ecee607e86cebcf1c08ad7
[yaml2obj] - Add a way to set default values for macros used in a YAML.

Currently we have to override all macros that are declared. But in many
cases it is convenient to use default values and to override only
a particular one or two.

This provides a way to set a default value for any macro:

```
Symbols:
  - Name: [[FOO=foo]]
```

Differential revision: https://reviews.llvm.org/D82455
llvm/test/tools/yaml2obj/macro.yaml
llvm/tools/yaml2obj/yaml2obj.cpp