Doxygen
vhdljjparser.h
浏览该文件的文档.
1 #ifndef VHDLJJPARSER_H
2 #define VHDLJJPARSER_H
3 
4 #include <vector>
5 #include <memory>
6 #include <string>
7 
8 #include "parserintf.h"
9 #include <stdio.h>
10 #include <stdlib.h>
11 #include <assert.h>
12 #include <ctype.h>
13 
14 #include "types.h"
15 #include "entry.h"
16 #include "vhdldocgen.h"
17 #include "config.h"
18 #include "util.h"
19 
21 //void parserVhdlfile(const char* inputBuffer);
22 
23 /** \brief VHDL parser using state-based lexical scanning.
24  *
25  * This is the VHDL language parser for doxygen.
26  */
28 {
29  public:
31  virtual ~VHDLOutlineParser();
32  void parseInput(const QCString &fileName,
33  const char *fileBuf,
34  const std::shared_ptr<Entry> &root,
35  ClangTUParser *clangParser);
36 
37  bool needsPreprocessing(const QCString &) const { return TRUE; }
38  void parsePrototype(const QCString &text);
39 
40 
41  // interface for generated parser code
42 
43  void setLineParsed(int tok);
44  int getLine(int tok);
45  int getLine();
46  void lineCount(const char*);
47  void lineCount();
48  void addProto(const char *s1,const char *s2,const char *s3,const char *s4,const char *s5,const char *s6);
49  //void addConfigureNode(const char* a,const char*b, bool,bool isLeaf,bool inlineConf);
50  void createFunction(const char *impure,uint64 spec,const char *fname);
51  void addVhdlType(const char *n,int startLine,int section, uint64 spec,const char* args,const char* type,Protection prot);
52  void addCompInst(const char *n, const char* instName, const char* comp,int iLine);
53  void handleCommentBlock(const QCString &doc,bool brief);
54  void handleFlowComment(const char*);
55  void initEntry(Entry *e);
56  void newEntry();
57  bool isFuncProcProced();
58  void pushLabel(QCString &,QCString&);
60  bool addLibUseClause(const QCString &type);
61  void mapLibPackage( Entry* root);
62  void createFlow();
63  void error_skipto(int kind);
64  void oneLineComment(QCString qcs);
65  void setMultCommentLine();
66  bool checkMultiComment(QCString& qcs,int line);
67  void insertEntryAtLine(std::shared_ptr<Entry> ce,int line);
69  int checkInlineCode(QCString & doc);
70  private:
71  struct Private;
72  std::unique_ptr<Private> p;
73 };
74 
75 
76 const EntryList &getVhdlInstList();
77 
78 QCString filter2008VhdlComment(const char *s);
79 
80 #endif
VHDLOutlineParser::getLine
int getLine()
Definition: vhdljjparser.cpp:720
VHDLOutlineParser::addVhdlType
void addVhdlType(const char *n, int startLine, int section, uint64 spec, const char *args, const char *type, Protection prot)
Definition: vhdljjparser.cpp:513
VHDLOutlineParser::handleCommentBlock
void handleCommentBlock(const QCString &doc, bool brief)
Definition: vhdljjparser.cpp:383
GEN_SEC
@ GEN_SEC
Definition: vhdljjparser.h:20
Protection
Protection
Protection level of members
Definition: types.h:26
VHDLOutlineParser::setMultCommentLine
void setMultCommentLine()
Definition: vhdljjparser.cpp:790
VHDLOutlineParser::getNameID
QCString getNameID()
returns a unique id for each record member.
Definition: vhdljjparser.cpp:255
types.h
This file contains a number of basic enums and types.
VHDLOutlineParser::VHDLOutlineParser
VHDLOutlineParser()
Definition: vhdljjparser.cpp:124
VHDLOutlineParser::isFuncProcProced
bool isFuncProcProced()
Definition: vhdljjparser.cpp:599
VHDLOutlineParser::p
std::unique_ptr< Private > p
Definition: vhdljjparser.h:71
VHDLOutlineParser::lineCount
void lineCount()
Definition: vhdljjparser.cpp:182
VHDLOutlineParser::handleFlowComment
void handleFlowComment(const char *)
Definition: vhdljjparser.cpp:260
VHDLOutlineParser::insertEntryAtLine
void insertEntryAtLine(std::shared_ptr< Entry > ce, int line)
Definition: vhdljjparser.cpp:826
VHDLOutlineParser::mapLibPackage
void mapLibPackage(Entry *root)
Definition: vhdljjparser.cpp:681
VHDLOutlineParser::checkInlineCode
int checkInlineCode(QCString &doc)
Definition: vhdljjparser.cpp:273
VHDLOutlineParser::checkMultiComment
bool checkMultiComment(QCString &qcs, int line)
Definition: vhdljjparser.cpp:806
VHDLOutlineParser::parseInput
void parseInput(const QCString &fileName, const char *fileBuf, const std::shared_ptr< Entry > &root, ClangTUParser *clangParser)
Parses a single input file with the goal to build an Entry tree.
Definition: vhdljjparser.cpp:132
entry.h
filter2008VhdlComment
QCString filter2008VhdlComment(const char *s)
Definition: vhdljjparser.cpp:862
VHDLOutlineParser::addLibUseClause
bool addLibUseClause(const QCString &type)
Definition: vhdljjparser.cpp:708
VHDLOutlineParser::initEntry
void initEntry(Entry *e)
Definition: vhdljjparser.cpp:195
VHDLOutlineParser::error_skipto
void error_skipto(int kind)
Definition: vhdljjparser.cpp:844
VHDLOutlineParser::addProto
void addProto(const char *s1, const char *s2, const char *s3, const char *s4, const char *s5, const char *s6)
Definition: vhdljjparser.cpp:628
parserintf.h
VHDLOutlineParser::~VHDLOutlineParser
virtual ~VHDLOutlineParser()
Definition: vhdljjparser.cpp:128
CONTEXT_SEC
@ CONTEXT_SEC
Definition: vhdljjparser.h:20
TRUE
#define TRUE
Definition: qcstring.h:36
VHDLOutlineParser::addCompInst
void addCompInst(const char *n, const char *instName, const char *comp, int iLine)
Definition: vhdljjparser.cpp:471
PARAM_SEC
@ PARAM_SEC
Definition: vhdljjparser.h:20
VHDLOutlineParser::pushLabel
void pushLabel(QCString &, QCString &)
Definition: vhdljjparser.cpp:612
VHDLOutlineParser::parsePrototype
void parsePrototype(const QCString &text)
Callback function called by the comment block scanner.
Definition: vhdljjparser.cpp:465
VHDLOutlineParser::newEntry
void newEntry()
Definition: vhdljjparser.cpp:210
EntryList
std::vector< std::shared_ptr< Entry > > EntryList
Definition: entry.h:336
VHDLOutlineParser::setLineParsed
void setLineParsed(int tok)
Definition: vhdljjparser.cpp:725
Entry
Represents an unstructured piece of information, about an entity found in the sources.
Definition: entry.h:61
VHDLOutlineParser
VHDL parser using state-based lexical scanning.
Definition: vhdljjparser.h:27
OutlineParserInterface
Abstract interface for outline parsers.
Definition: parserintf.h:42
VHDLOutlineParser::createFunction
void createFunction(const char *impure, uint64 spec, const char *fname)
Definition: vhdljjparser.cpp:551
config.h
ClangTUParser
Clang parser object for a single translation unit, which consists of a source file and the directly o...
Definition: clangparser.h:21
PROTECTED_SEC
@ PROTECTED_SEC
Definition: vhdljjparser.h:20
getVhdlInstList
const EntryList & getVhdlInstList()
Definition: vhdljjparser.cpp:839
VHDLOutlineParser::popLabel
QCString popLabel(QCString &q)
Definition: vhdljjparser.cpp:618
util.h
A bunch of utility functions.
VHDLOutlineParser::createFlow
void createFlow()
Definition: vhdljjparser.cpp:740
VHDLOutlineParser::Private
Definition: vhdljjparser.cpp:58
uint64
uint64_t uint64
Definition: qcstring.h:43
VHDLOutlineParser::needsPreprocessing
bool needsPreprocessing(const QCString &) const
Returns TRUE if the language identified by extension needs the C preprocessor to be run before feed t...
Definition: vhdljjparser.h:37
vhdldocgen.h
VHDLOutlineParser::oneLineComment
void oneLineComment(QCString qcs)
Definition: vhdljjparser.cpp:795
QCString
This is an alternative implementation of QCString.
Definition: qcstring.h:108