open-nomad/jobspec2
Mahmood Ali 04bfeacc5b hcl2: Use the actual string snippet as it appears from undefined
With the updated undefined variable code, we attempt to pick the text of
`${....}` verbatim from the hcl body. Previously, we'd attempt to
regenerate the string from the AST and pray it matches input; the
generation is lossy, as the same AST can represent multiple variations
(e.g. `${v.0}` and `${v[0]}` have the same HCLv2 AST). In this change,
we attempt to go back to the hcl2 source and find the string snippet
corresponding to the variable reference.
2021-04-07 16:45:37 -04:00
..
addrs copy variables files from Packer 2020-11-09 14:35:02 -05:00
hclutil hclv2: handle block labels 2020-10-26 16:24:43 -04:00
test-fixtures hclv2 tests: test complex config configuration 2020-10-26 16:20:41 -04:00
functions.go address review feedback 2020-10-22 11:49:37 -04:00
hcl_conversions.go tests: add tests for invalid syntax cases 2021-02-01 12:51:51 -05:00
helper_test.go appease deadcode linter 2020-11-12 11:44:49 -05:00
parse.go jobspec2: decode returns error in more cases (#9613) 2020-12-16 07:49:09 -08:00
parse_job.go appease deadcode linter 2020-11-12 11:44:49 -05:00
parse_map.go Restrict HCL special casing of map[string]interface{} fields 2020-11-12 11:35:39 -05:00
parse_test.go hcl2: Use the actual string snippet as it appears from undefined 2021-04-07 16:45:37 -04:00
types.config.go hcl2: Use the actual string snippet as it appears from undefined 2021-04-07 16:45:37 -04:00
types.variables.go Apply some suggested fixes from staticcheck (#9598) 2020-12-10 07:29:18 -08:00