opentofu/internal/addrs
Martin Atkins 4f99815163 addrs: Target is a fmt.Stringer
We have some test code that includes *addrs.Target values in fmt calls with
the %s and %q verbs, but that type was not actually a fmt.Stringer before.

Go 1.26 is introducing some new checks that cause those uses to cause
failures when building those tests. We could potentially change the tests
to produce the string representation in a different way, but we typically
expect our address types to be "stringable" in this way, so instead we'll
just make Target be a fmt.Stringer, delegating to the String method of
the underlying addrs.Targetable implementation. The addrs.Targetable
interface requires a String method, so all implementations are guaranteed
to support this.

Note that we're not actually using Go 1.26 yet at the time of this commit,
but this is an early fix to make the upgrade easier later. I verified this
using go1.26rc1.

Signed-off-by: Martin Atkins <mart@degeneration.co.uk>
2025-12-18 10:59:03 -08:00
..
check.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
check_rule.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
check_rule_diagnostic.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
check_rule_diagnostic_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
checkable.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
checkablekind_string.go Add input validation into the 'checks' outputs and tracking (#33481) 2023-07-10 11:33:45 +01:00
checkruletype_string.go go.mod: Upgrade various golang.org/x/* dependencies 2025-10-10 08:23:54 -07:00
count_attr.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
doc.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
for_each_attr.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
input_variable.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
instance_key.go addrs: Modeling of "wildcard" instance keys 2025-10-27 10:15:41 -07:00
instance_key_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
local_value.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
map.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
map_test.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
module.go Compare ModuleInstance to Module without allocating, and similar (#2261) 2024-12-12 12:47:57 -05:00
module_call.go Fix typos (#1905) 2024-08-29 13:20:33 -04:00
module_instance.go lang/eval: PlanningOracle.AwaitResourceInstancesCompletion 2025-10-27 10:15:41 -07:00
module_instance_test.go Address linting issues in addrs package (#2777) 2025-05-09 14:50:37 -04:00
module_package.go Adopt OpenTofu's own "svchost" module 2025-06-12 09:37:59 -07:00
module_source.go lang/eval: Some initial support for child module calls 2025-10-27 10:15:41 -07:00
module_source_resolve.go lang/eval: Some initial support for child module calls 2025-10-27 10:15:41 -07:00
module_source_test.go Adopt OpenTofu's own "svchost" module 2025-06-12 09:37:59 -07:00
module_test.go Address linting issues in addrs package (#2777) 2025-05-09 14:50:37 -04:00
move_endpoint.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
move_endpoint_kind.go go.mod: Use the new "tool" directive 2025-10-10 07:06:56 -03:00
move_endpoint_module.go Implicit moves for modules (#3327) 2025-10-15 09:10:15 -03:00
move_endpoint_module_test.go Compare ModuleInstance to Module without allocating, and similar (#2261) 2024-12-12 12:47:57 -05:00
move_endpoint_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
moveable.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
moveendpointkind_string.go addrs: MoveEndpointInModule 2021-07-14 17:37:48 -07:00
output_value.go Fix typos (#1905) 2024-08-29 13:20:33 -04:00
output_value_test.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
parse_ref.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
parse_ref_test.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
parse_target.go addrs: Target is a fmt.Stringer 2025-12-18 10:59:03 -08:00
parse_target_test.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
path_attr.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
provider.go Adopt OpenTofu's own "svchost" module 2025-06-12 09:37:59 -07:00
provider_config.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
provider_config_test.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
provider_correct.go lang/eval: Bind PlanningOracle to PlanGlue 2025-10-27 10:15:41 -07:00
provider_function.go Unify core functions address handling (#3445) 2025-10-31 08:41:52 +02:00
provider_test.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
referenceable.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
removable.go Add support for removed block (#1158) 2024-02-21 10:31:44 +02:00
remove_endpoint.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
remove_endpoint_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
resource.go addrs: Modeling of "wildcard" instance keys 2025-10-27 10:15:41 -07:00
resource_phase.go Fix typos (#1905) 2024-08-29 13:20:33 -04:00
resource_test.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
resourcemode_string.go Feature branch: Ephemeral resources (#2852) 2025-08-04 16:39:12 +03:00
self.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
set.go collections+addrs: Build sets from iter.Seq[T] 2025-10-27 10:15:41 -07:00
target_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
targetable.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
testing.go Replace github.com/go-test/deep with go-cmp 2025-10-13 08:17:40 -07:00
tf_attr.go feat: Add support for tofu.workspace which will be resolved in the same way as terraform.workspace (#1305) 2024-08-01 08:14:34 -04:00
traversal.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
traversal_test.go Detect when provider and resource/module have identical for_each (#2186) 2024-12-03 14:02:27 -05:00
unique_key.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00
unique_key_test.go Update copyright notice (#1232) 2024-02-08 09:48:59 +00:00