static int convertYAML(yaml::Input &YIn, raw_ostream &Out, ConvertFuncPtr Convert) { unsigned CurDocNum = 0; do { if (++CurDocNum == DocNum) return Convert(YIn, Out); } while (YIn.nextDocument()); errs() << "yaml2obj: Cannot find the " << DocNum << llvm::getOrdinalSuffix(DocNum) << " document\n"; return 1; }