The current version of the Terraform language grammar contains a list of built-in functions. However, as we don't know which version of Terraform a user uses, it is highly possible that the list is either incomplete or contains removed functions.
https://github.com/hashicorp/vscode-terraform/blob/562c7cd7b27b5599b4fb1d4ae21b4fc63639dd91/syntaxes/terraform.tmGrammar.json#L750
To improve the syntax highlighting of built-in functions, we should remove the static list from the grammar file and use semantic token highlighting via the LS. The language server has a better understanding of which Terraform version is used and which functions are available in this version.
The current version of the Terraform language grammar contains a list of built-in functions. However, as we don't know which version of Terraform a user uses, it is highly possible that the list is either incomplete or contains removed functions.
https://github.com/hashicorp/vscode-terraform/blob/562c7cd7b27b5599b4fb1d4ae21b4fc63639dd91/syntaxes/terraform.tmGrammar.json#L750
To improve the syntax highlighting of built-in functions, we should remove the static list from the grammar file and use semantic token highlighting via the LS. The language server has a better understanding of which Terraform version is used and which functions are available in this version.