github.com/terraform-linters/tflint-plugin-sdk@v0.22.0/hclext/doc.go (about) 1 // Package hclext is an extension of package hcl for TFLint. 2 // 3 // The goal of this package is to work with nested hcl.BodyContent. 4 // In the various functions provided by the package hcl, hcl.Block 5 // nests hcl.Body as body. However, since hcl.Body is an interface, 6 // the nested body cannot be sent over a wire protocol. 7 // 8 // In this package, redefine hcl.Block as hclext.Block nests BodyContent, 9 // not Body, which is an interface. Some functions and related structures 10 // have been redefined to make hclext.Block behave like the package hcl. 11 // 12 // For example, Content/PartialContent takes hclext.BodySchema instead of 13 // hcl.BodySchema and returns hclext.BodyContent. In hclext.BodySchema, 14 // you can declare the structure of the nested body as the block schema. 15 // This allows you to send the schema and its results of configurations 16 // that contain nested bodies via gRPC. 17 package hclext