Add public API generation with cr.makePublic() and handle it in compiler pass