We present high-resolution (R similar to 50,000) observations of near-IR transitions of CO and CN of the five known hydrogen-deficient carbon (HdC) stars and four R Coronae Borealis (RCB) stars. We perform an abundance analysis of these stars by using spectrum synthesis and state-of-the-art MARCS model atmospheres for cool hydrogen-deficient stars. Our analysis confirms reports by Clayton and colleagues that those HdC stars exhibiting CO lines in their spectrum and the cool RCB star SAps are strongly enriched in (18)O(with (16)O/(18)Oratios ranging from 0.3 to 16). Nitrogen and carbon are in the form of (14)N and (12)C, respectively. Elemental abundances for CNO are obtained from C I, Ci2, CN, and CO lines. Difficulties in deriving the carbon abundance are discussed. Abundances of Na from Na I lines and S from S I lines are obtained. Elemental and isotopic CNO abundances suggest that HdC and RCB stars may be related objects, and that they probably formed from a merger of an He white dwarf with a C-O white dwarf.Robert A. Welch Foundation of Houston, TexasSwedish Research CouncilGS-2006A-C-13GS-2007A-DD-1McDonald Observator