Simplify code by moving polyfill cue compiler to sub-package cc

Signed-off-by: Solomon Hykes <sh.github.6811@hykes.org>
This commit is contained in:
Solomon Hykes
2021-02-07 07:36:21 +00:00
parent 622de21883
commit 612a25fb9f
26 changed files with 372 additions and 350 deletions

View File

@@ -6,6 +6,8 @@ import (
"os"
cueflow "cuelang.org/go/tools/flow"
"dagger.cloud/go/dagger/cc"
)
var ErrNotExist = os.ErrNotExist
@@ -16,7 +18,7 @@ type Executable interface {
Walk(context.Context, func(*Op) error) error
}
func newExecutable(v *Value) (Executable, error) {
func newExecutable(v *cc.Value) (Executable, error) {
// NOTE: here we need full spec validation,
// so we call NewScript, NewComponent, NewOp.
if script, err := NewScript(v); err == nil {