lang: funcs: structs: Improve naming

These could print nicer for debugging.
This commit is contained in:
James Shubin
2024-12-08 16:24:42 -05:00
parent 5ff4f0456a
commit 28f5b8331a
34 changed files with 247 additions and 243 deletions

View File

@@ -56,9 +56,10 @@ func (obj *ConstFunc) String() string {
if obj.NameHint != "" {
return obj.NameHint
}
if obj.Value != nil && obj.Value.Type() != nil {
return fmt.Sprintf("%s: %s(%s)", ConstFuncName, obj.Value.Type().String(), obj.Value.String())
}
return ConstFuncName
//return fmt.Sprintf("%s: %s(%s)", ConstFuncName, obj.Value.Type().String(), obj.Value.String())
//return fmt.Sprintf("%s(%s)", obj.Value.Type().String(), obj.Value.String())
}
// Validate makes sure we've built our struct properly.