Polly 23.0.0git
extract_interface.cc File Reference
#include "isl_config.h"
#include <assert.h>
#include <iostream>
#include <stdlib.h>
#include <type_traits>
#include <memory>
#include <llvm/Support/raw_ostream.h>
#include <llvm/Support/CommandLine.h>
#include <llvm/Support/ManagedStatic.h>
#include <clang/AST/ASTConsumer.h>
#include <clang/Basic/DiagnosticOptions.h>
#include <clang/Basic/FileSystemOptions.h>
#include <clang/Frontend/CompilerInstance.h>
#include <clang/Frontend/TextDiagnosticPrinter.h>
#include <clang/Frontend/Utils.h>
#include <clang/Lex/HeaderSearch.h>
#include <clang/Lex/PreprocessorOptions.h>
#include <clang/Lex/Preprocessor.h>
#include <clang/Parse/ParseAST.h>
#include <clang/Sema/Sema.h>
#include "isl-interface/clang_wrap.h"
#include "extract_interface.h"
#include "generator.h"
#include "python.h"
#include "plain_cpp.h"
#include "cpp_conversion.h"
#include "template_cpp.h"

Go to the source code of this file.

Classes

struct  MyASTConsumer
struct  Extractor

Functions

static llvm::cl::opt< string > InputFilename (llvm::cl::Positional, llvm::cl::Required, llvm::cl::desc("<input file>"))
static llvm::cl::list< string > Includes ("I", llvm::cl::desc("Header search path"), llvm::cl::value_desc("path"), llvm::cl::Prefix)
static llvm::cl::opt< string > OutputLanguage (llvm::cl::Required, llvm::cl::ValueRequired, "language", llvm::cl::desc("Bindings to generate"), llvm::cl::value_desc("name"))
bool has_annotation (Decl *decl, const char *name)
static bool is_exported (Decl *decl)
static void generate (MyASTConsumer &consumer, SourceManager &SM)
int main (int argc, char *argv[])

Function Documentation

◆ generate()

void generate ( MyASTConsumer & consumer,
SourceManager & SM )
static

◆ has_annotation()

bool has_annotation ( Decl * decl,
const char * name )

◆ Includes()

llvm::cl::list< string > Includes ( "I" ,
llvm::cl::desc("Header search path") ,
llvm::cl::value_desc("path") ,
llvm::cl::Prefix  )
static

Referenced by Extractor::add_paths().

◆ InputFilename()

llvm::cl::opt< string > InputFilename ( llvm::cl::Positional ,
llvm::cl::Required ,
llvm::cl::desc("<input file>")  )
static

Referenced by main().

◆ is_exported()

bool is_exported ( Decl * decl)
static

Definition at line 107 of file extract_interface.cc.

References has_annotation().

Referenced by MyASTConsumer::HandleTopLevelDecl().

◆ main()

int main ( int argc,
char * argv[] )

Definition at line 254 of file extract_interface.cc.

References InputFilename(), and isl::clang::Wrap::invoke().

◆ OutputLanguage()

llvm::cl::opt< string > OutputLanguage ( llvm::cl::Required ,
llvm::cl::ValueRequired ,
"language" ,
llvm::cl::desc("Bindings to generate") ,
llvm::cl::value_desc("name")  )
static

Referenced by generate().