[guidance] split h_ref and v_ref into h and c files