Detail:"A "+sourceLabel+" reference must have three parts separated by periods: the keyword \""+sourceLabel+"\", the builder type name, and the source name.",
Subject:t.SourceRange().Ptr(),
})
returnNoSource,diags
}
ift.RootName()!=sourceLabel{
diags=append(diags,&hcl.Diagnostic{
Severity:hcl.DiagError,
Summary:"Invalid "+sourceLabel+" reference",
Detail:"The first part of an source reference must be the keyword \""+sourceLabel+"\".",
Subject:t[0].SourceRange().Ptr(),
})
returnNoSource,diags
}
btStep,ok:=t[1].(hcl.TraverseAttr)
if!ok{
diags=append(diags,&hcl.Diagnostic{
Severity:hcl.DiagError,
Summary:"Invalid "+sourceLabel+" reference",
Detail:"The second part of an "+sourceLabel+" reference must be an identifier giving the builder type of the "+sourceLabel+".",
Subject:t[1].SourceRange().Ptr(),
})
returnNoSource,diags
}
nameStep,ok:=t[2].(hcl.TraverseAttr)
if!ok{
diags=append(diags,&hcl.Diagnostic{
Severity:hcl.DiagError,
Summary:"Invalid "+sourceLabel+" reference",
Detail:"The third part of an "+sourceLabel+" reference must be an identifier giving the name of the "+sourceLabel+".",