-
Notifications
You must be signed in to change notification settings - Fork 23
Description
Currently we decode all module calls into a map, where the key is the module reference name and ignore any module calls which do not have a reference name + override modules of the same name.
module "" {
source = ""
}
module "" {
source = ""
}
Similarly we decode required providers into a map, keyed off provider local name and override any requirements with the same name.
terraform {
required_providers {
name = {
source = ""
}
name = {
source = ""
}
}
}
Map of course makes lookups much easier, but it makes it practically impossible to track unknown modules and provide some IntelliSense within those.
For module calls in particular map is a reasonable structure for hashicorp/terraform-ls#598 and hashicorp/terraform-ls#725 but unnamed modules may also be helpful to parse in the context of hashicorp/terraform-ls#869
Similarly hashicorp/terraform-ls#871 may benefit from decoded requirements of the same name.
Originally posted by @radeksimko in #106 (comment)