Better error checking for Rec and Value