8000 cue: ResolveReferences option not work in method "Syntax" · Issue #867 · cue-lang/cue · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
cue: ResolveReferences option not work in method "Syntax"  #867
Closed
@cueckoo

Description

@cueckoo

Originally opened by @leejanee in cuelang/cue#867

What version of CUE are you using (cue version)?

$ cue version
v0.3.0-beta.8

What did you do?

The code is as follows

       var src =`
t: {name: string}
output: [...t]
`
	var r cue.Runtime
	inst,_:=r.Compile("-",src)
	ct,_:=format.Node(inst.Value().Lookup("output").Syntax(cue.ResolveReferences(true)))
	fmt.Println(string(ct))

After running the code,I get

[...t]

But import the v0.2.2 version, The result is as follows

[...{
        name: string
}]

and, This is what i expected

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0