Doxygen
|
#include <stdint.h>
#include <vector>
#include <unordered_map>
#include <string>
#include <stack>
#include <stdio.h>
#include "pycode.h"
#include "message.h"
#include "scanner.h"
#include "entry.h"
#include "doxygen.h"
#include "outputlist.h"
#include "util.h"
#include "membername.h"
#include "searchindex.h"
#include "config.h"
#include "groupdef.h"
#include "classlist.h"
#include "filedef.h"
#include "namespacedef.h"
#include "tooltip.h"
#include "scopedtypevariant.h"
#include "symbolresolver.h"
#include "debug.h"
#include "doxygen_lex.h"
#include "pycode.l.h"
Go to the source code of this file.
Classes | |
struct | pycodeYY_state |
struct | PythonCodeParser::Private |
Macros | |
#define | YY_TYPEDEF_YY_SCANNER_T |
#define | DBG_CTX(x) |
#define | YY_NO_INPUT 1 |
#define | YY_NO_UNISTD_H 1 |
#define | YY_INPUT(buf, result, max_size) |
Typedefs | |
typedef yyguts_t * | yyscan_t |
Functions | |
static const char * | stateToString (int state) |
static void | startCodeLine (yyscan_t yyscanner) |
static int | countLines (yyscan_t yyscanner) |
static void | setCurrentDoc (yyscan_t yyscanner, const QCString &anchor) |
static void | addToSearchIndex (yyscan_t yyscanner, const QCString &text) |
static const ClassDef * | stripClassName (yyscan_t yyscanner, const QCString &s, Definition *d) |
static void | codify (yyscan_t yyscanner, const QCString &text) |
static void | endCodeLine (yyscan_t yyscanner) |
static void | nextCodeLine (yyscan_t yyscanner) |
static void | writeMultiLineCodeLink (yyscan_t yyscanner, OutputCodeList &ol, const Definition *d, const QCString &text) |
static void | startFontClass (yyscan_t yyscanner, const char *s, bool specialComment=false) |
static void | endFontClass (yyscan_t yyscanner, bool specialComment=false) |
static void | codifyLines (yyscan_t yyscanner, const QCString &text) |
static bool | getLinkInScope (yyscan_t yyscanner, const QCString &c, const QCString &m, const QCString &memberText, OutputCodeList &ol, const QCString &text) |
static bool | getLink (yyscan_t yyscanner, const QCString &className, const QCString &memberName, OutputCodeList &ol, const QCString &text=QCString()) |
static void | generateClassOrGlobalLink (yyscan_t yyscanner, OutputCodeList &ol, const QCString &clName, bool typeOnly=FALSE) |
static void | generateFunctionLink (yyscan_t yyscanner, OutputCodeList &ol, const QCString &funcName) |
static bool | findMemberLink (yyscan_t yyscanner, OutputCodeList &ol, const Definition *sym, const QCString &symName) |
static void | findMemberLink (yyscan_t yyscanner, OutputCodeList &ol, const QCString &symName) |
static void | incrementFlowKeyWordCount (yyscan_t yyscanner) |
static void | adjustScopesAndSuites (yyscan_t yyscanner, unsigned indentLength) |
static int | yyread (yyscan_t yyscanner, char *buf, int max_size) |
static void | pop_state (yyscan_t yyscanner) |
static const char * | getLexerFILE () |
int | yylex (yyscan_t yyscanner) |
static void | codeFolding (yyscan_t yyscanner, const Definition *d) |
#define YY_INPUT | ( | buf, | |
result, | |||
max_size ) |
Definition at line 862 of file pycode.l.
References FALSE, and Doxygen::searchIndex.
|
static |
Examines current stack of white-space indentations; re-syncs the parser with the correct scope.
Definition at line 792 of file pycode.l.
|
static |
Definition at line 901 of file pycode.l.
References Config_getBool, Definition::getEndBodyLine(), and Definition::getStartDefLine().
Definition at line 1016 of file pycode.l.
Referenced by findMemberLink().
Definition at line 1133 of file pycode.l.
References QCString::data(), FALSE, QCString::isEmpty(), nextCodeLine(), and TRUE.
|
static |
counts the number of lines in the input
Definition at line 823 of file pycode.l.
|
static |
Definition at line 1024 of file pycode.l.
References endFontClass().
|
static |
Definition at line 1116 of file pycode.l.
|
static |
Definition at line 1417 of file pycode.l.
References addDocCrossReference(), DBG_CTX, Definition::definitionType(), FALSE, Definition::getOuterScope(), ClassDef::isBaseClass(), Definition::name(), qPrint(), toClassDef(), toMemberDef(), TRUE, Definition::TypeClass, Definition::TypeMember, and writeMultiLineCodeLink().
Referenced by findMemberLink().
|
static |
Definition at line 1455 of file pycode.l.
References codify(), findMemberLink(), and Doxygen::symbolMap.
|
static |
Definition at line 1233 of file pycode.l.
References addDocCrossReference(), addToSearchIndex(), codifyLines(), DBG_CTX, Definition::displayName(), QCString::findRev(), Definition::getBodyDef(), getClass(), MemberDef::getGroupDef(), getLink(), ClassDef::getMemberByName(), NamespaceDef::getMemberByName(), Definition::getOuterScope(), getResolvedNamespace(), Doxygen::globalScope, ScopedTypeVariant::isDummy(), QCString::isEmpty(), Definition::isLinkable(), QCString::left(), QCString::length(), Definition::name(), qPrint(), QCString::right(), stripClassName(), substitute(), MemberDef::typeString(), and writeMultiLineCodeLink().
|
static |
Definition at line 1374 of file pycode.l.
References LocalDef::baseClasses(), DBG_CTX, QCString::findRev(), generateClassOrGlobalLink(), getLink(), QCString::isEmpty(), QCString::left(), QCString::length(), ScopedTypeVariant::localDef(), qPrint(), removeRedundantWhiteSpace(), QCString::right(), QCString::str(), and QCString::stripWhiteSpace().
|
inlinestatic |
|
static |
Definition at line 1205 of file pycode.l.
References FALSE, getLinkInScope(), QCString::isEmpty(), QCString::prepend(), removeRedundantWhiteSpace(), and TRUE.
|
static |
Definition at line 1163 of file pycode.l.
References addDocCrossReference(), addToSearchIndex(), GetDefInput::currentFile, FALSE, GetDefResult::found, Definition::getBodyDef(), getDefs(), MemberDef::getGroupDef(), Definition::getOuterScope(), Doxygen::globalScope, GetDefInput::insideCode, QCString::isEmpty(), Definition::isLinkable(), GetDefResult::md, stripClassName(), TRUE, MemberDef::typeString(), and writeMultiLineCodeLink().
|
static |
Definition at line 1477 of file pycode.l.
References Doxygen::countFlowKeywordsMutex, MemberDefMutable::incrementFlowKeyWordCount(), and toMemberDefMutable().
|
static |
Definition at line 1034 of file pycode.l.
References endCodeLine(), and startCodeLine().
|
inlinestatic |
Definition at line 844 of file pycode.l.
References FALSE, Doxygen::searchIndex, and TRUE.
|
static |
start a new line of code, inserting a line number if yyextra->sourceFileDef is TRUE. If a definition starts at the current line, then the line number is linked to the documentation of that definition.
Definition at line 948 of file pycode.l.
References codeFolding(), FALSE, Definition::getOutputFileBase(), Definition::getReference(), Definition::isLinkableInProject(), Definition::name(), setCurrentDoc(), QCString::sprintf(), and TRUE.
|
static |
Definition at line 1097 of file pycode.l.
References endFontClass(), and qstrcmp().
|
static |
References FALSE.
|
static |
Definition at line 872 of file pycode.l.
References extractClassNameFromType().
|
static |
writes a link to a fragment text that may span multiple lines, inserting line numbers for each line. If text contains newlines, the link will be split into multiple links with the same destination, one for each line.
Definition at line 1055 of file pycode.l.
References Definition::anchor(), Definition::briefDescriptionAsTooltip(), Definition::codeSymbolType(), Config_getBool, QCString::data(), FALSE, Definition::getOutputFileBase(), Definition::getReference(), QCString::isEmpty(), nextCodeLine(), TRUE, and OutputCodeList::writeCodeLink().
int yylex | ( | yyscan_t | yyscanner | ) |
Definition at line 217 of file pycode.l.
|
static |
Definition at line 771 of file pycode.l.