Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
core/runtime: panic if cueexperiment errors
It was noticed that bad values of CUE_EXPERIMENT don't produce errors when using the CUE Go public API. In particular, calls to `cuecontext.New()` seem to work even with bad CUE_EXPERIMENTS. This was found because a testscript had a typo: ``` env CUE_EXPERIMENT=evalv0=0 exec go run main.go -- main.go -- package main // some code that used cuecontext.New() ``` The cause is that in two places, we don't inspect the error from `cueexperiment.Init()`. Because there is no nice error return path, we instead panic. Signed-off-by: Matthew Sackman <[email protected]> Change-Id: I71a73775ee55085341c26f6c795c3db33b7b3da9 Dispatch-Trailer: {"type":"trybot","CL":1208729,"patchset":1,"ref":"refs/changes/29/1208729/1","targetBranch":"master"}
- Loading branch information