WIP: keep last value/result cache associated with scopes