arphaman added a comment. Nit: Could you please try to extract the shared code into a function, e.g.
Optional<std::string> overrideMacOSTripleDefaultVersion(const llvm::Triple &Triple, ... OSTy, ... TheDriver) { if (Triple.getOSMajorVersion()) return None; llvm::Triple SystemTriple(llvm::sys::getProcessTriple()); if (SystemTriple.isMacOSX()) return getOSVersion(OSTy, SystemTriple, TheDriver)); return None; } Repository: rC Clang https://reviews.llvm.org/D48849 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits