MCPcopy
hub / github.com/hashicorp/hcl / MissingItemRange

Method MissingItemRange

json/structure.go:222–233  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

220}
221
222func (b *body) MissingItemRange() hcl.Range {
223 switch tv := b.val.(type) {
224 case *objectVal:
225 return tv.CloseRange
226 case *arrayVal:
227 return tv.OpenRange
228 default:
229 // Should not happen in correct operation, but might show up if the
230 // input is invalid and we are producing partial results.
231 return tv.StartRange()
232 }
233}
234
235func (b *body) unpackBlock(v node, typeName string, typeRange *hcl.Range, labelsLeft []string, labelsUsed []string, labelRanges []hcl.Range, blocks *hcl.Blocks) (diags hcl.Diagnostics) {
236 if len(labelsLeft) > 0 {

Callers 1

PartialContentMethod · 0.95

Calls 1

StartRangeMethod · 0.65

Tested by

no test coverage detected