doc parsing. Add @method and @callback for
checkings and few other refactoring/cleanup.
// rdar://13094352.