def struct_work
import bendvy-ecs-core@0.1.0.3/decode_data.bend as DecodeDataimport Base
130def struct_work(fields:List<&2,NamedCodec>,+values:List<&2,Field>,+path:String,rest:List<&2,Work>) -> List<&2,Work>:
131 match fields:
132 case []: rest
133 case NamedCodec{+name,codec} <> tail: Work{codec,field(name,values),path ++ "." ++ name} <> struct_work(tail,values,path,rest)