cue
cue copied to clipboard
eval: nested matchN can be slow
What version of CUE are you using (cue version)?
8a6ed2c44ebc23549793d3fdd71523b88523b542
Does this issue reproduce with the latest stable release?
N/A
What did you do?
exec cue vet file.cue
-- file.cue --
_x0: matchN(4, [int, int, int, int])
_x1: matchN(4, [_x0, _x0, _x0, _x0])
_x2: matchN(4, [_x1, _x1, _x1, _x1])
_x3: matchN(4, [_x2, _x2, _x2, _x2])
_x4: matchN(4, [_x3, _x3, _x3, _x3])
_x5: matchN(4, [_x4, _x4, _x4, _x4])
_x6: matchN(4, [_x5, _x5, _x5, _x5])
_x7: matchN(4, [_x6, _x6, _x6, _x6])
_x8: matchN(4, [_x7, _x7, _x7, _x7])
_x9: matchN(4, [_x8, _x8, _x8, _x8])
x: 3 & _x9
What did you expect to see?
A test that does not take that long to run.
What did you see instead?
A 7 second run time.