Fix compile for R2