github.com/rstandt/terraform@v0.12.32-0.20230710220336-b1063613405c/configs/configupgrade/testdata/valid/noop-exprs/want/exprs.tf (about) 1 locals { 2 # Arithmetic 3 add = 1 + 2 4 sub = 1 - 2 5 mul = 1 * 2 6 mod = 4 % 2 7 and = true && true 8 or = true || true 9 equal = 1 == 2 10 not_equal = 1 != 2 11 less_than = 1 < 2 12 greater_than = 1 > 2 13 less_than_eq = 1 <= 2 14 greater_than_eq = 1 >= 2 15 neg = -local.add 16 17 # Call 18 call_no_args = foo() 19 call_one_arg = foo(1) 20 call_two_args = foo(1, 2) 21 22 # Conditional 23 cond = true ? 1 : 2 24 25 # Index 26 index_str = foo["a"] 27 index_num = foo[1] 28 29 # Variable Access 30 var_access_single = foo 31 var_access_dot = foo.bar 32 var_access_splat = foo.bar.*.baz 33 }