chore(tvix/eval): add variant_size_differences warning for OpCode

This makes it possible to quickly detect code errors that might blow
up the size of the OpCode type.

Change-Id: I7662dd0aa30c4762c0f9e4fa346418c9ca8b9994
Reviewed-on: https://cl.tvl.fyi/c/depot/+/6177
Tested-by: BuildkiteCI
Reviewed-by: grfn <grfn@gws.fyi>
This commit is contained in:
Vincent Ambo 2022-08-12 17:19:14 +03:00 committed by tazjin
parent e70ef017ff
commit d952b29fca

View file

@ -7,6 +7,7 @@ pub struct ConstantIdx(pub usize);
#[derive(Clone, Copy, Debug)]
pub struct CodeIdx(pub usize);
#[warn(variant_size_differences)]
#[derive(Clone, Copy, Debug)]
pub enum OpCode {
// Push a constant onto the stack.