build with 2.13 Updated the visibility checking to be more generic and able to handle more cases. Change-Id: I988541cf36857f7e26cbbb417fe21ab5c1a6f7a2