clang 20.0.0git
APINotesYAMLCompiler.h
Go to the documentation of this file.
1//===-- APINotesYAMLCompiler.h - API Notes YAML Format Reader ---*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLVM_CLANG_APINOTES_APINOTESYAMLCOMPILER_H
10#define LLVM_CLANG_APINOTES_APINOTESYAMLCOMPILER_H
11
12#include "llvm/ADT/StringRef.h"
13#include "llvm/Support/SourceMgr.h"
14#include "llvm/Support/raw_ostream.h"
15
16namespace clang {
17class FileEntry;
18} // namespace clang
19
20namespace clang {
21namespace api_notes {
22/// Parses the APINotes YAML content and writes the representation back to the
23/// specified stream. This provides a means of testing the YAML processing of
24/// the APINotes format.
25bool parseAndDumpAPINotes(llvm::StringRef YI, llvm::raw_ostream &OS);
26
27/// Converts API notes from YAML format to binary format.
28bool compileAPINotes(llvm::StringRef YAMLInput, const FileEntry *SourceFile,
29 llvm::raw_ostream &OS,
30 llvm::SourceMgr::DiagHandlerTy DiagHandler = nullptr,
31 void *DiagHandlerCtxt = nullptr);
32} // namespace api_notes
33} // namespace clang
34
35#endif
Cached information about one file (either on disk or in the virtual file system).
Definition: FileEntry.h:300
bool compileAPINotes(llvm::StringRef YAMLInput, const FileEntry *SourceFile, llvm::raw_ostream &OS, llvm::SourceMgr::DiagHandlerTy DiagHandler=nullptr, void *DiagHandlerCtxt=nullptr)
Converts API notes from YAML format to binary format.
bool parseAndDumpAPINotes(llvm::StringRef YI, llvm::raw_ostream &OS)
Parses the APINotes YAML content and writes the representation back to the specified stream.
The JSON file list parser is used to communicate input to InstallAPI.