public TranslationUnit CreateTranslationUnit(string filename, string[] clangArgs = null, UnsavedFile[] unsavedFiles = null, TranslationUnitFlags options = TranslationUnitFlags.None) { if (!System.IO.File.Exists(filename)) { throw new System.IO.FileNotFoundException("Couldn't find input file.", filename); } clangArgs = clangArgs ?? new string[0]; unsavedFiles = unsavedFiles ?? new UnsavedFile[0]; return new TranslationUnit( filename, Interop.clang_parseTranslationUnit( Native, filename, clangArgs, clangArgs.Length, unsavedFiles.Select(f => f.Native).ToArray(), (uint)unsavedFiles.Length, options)); }