Classes | Macros | Typedefs | Functions | Variables
pycode.cpp File Reference
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <stdlib.h>
#include <qvaluestack.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"

Go to the source code of this file.

Classes

struct  yy_buffer_state
 
struct  yy_trans_info
 
class  PyVariableContext
 
class  PyVariableContext::Scope
 
class  PyCallContext
 
struct  PyCallContext::Ctx
 

Macros

#define YY_INT_ALIGNED   short int
 
#define yy_create_buffer   pycodeYY_create_buffer
 
#define yy_delete_buffer   pycodeYY_delete_buffer
 
#define yy_flex_debug   pycodeYY_flex_debug
 
#define yy_init_buffer   pycodeYY_init_buffer
 
#define yy_flush_buffer   pycodeYY_flush_buffer
 
#define yy_load_buffer_state   pycodeYY_load_buffer_state
 
#define yy_switch_to_buffer   pycodeYY_switch_to_buffer
 
#define yyin   pycodeYYin
 
#define yyleng   pycodeYYleng
 
#define yylex   pycodeYYlex
 
#define yylineno   pycodeYYlineno
 
#define yyout   pycodeYYout
 
#define yyrestart   pycodeYYrestart
 
#define yytext   pycodeYYtext
 
#define yywrap   pycodeYYwrap
 
#define yyalloc   pycodeYYalloc
 
#define yyrealloc   pycodeYYrealloc
 
#define yyfree   pycodeYYfree
 
#define FLEX_SCANNER
 
#define YY_FLEX_MAJOR_VERSION   2
 
#define YY_FLEX_MINOR_VERSION   5
 
#define YY_FLEX_SUBMINOR_VERSION   35
 
#define FLEX_BETA
 
#define FLEXINT_H
 
#define INT8_MIN   (-128)
 
#define INT16_MIN   (-32767-1)
 
#define INT32_MIN   (-2147483647-1)
 
#define INT8_MAX   (127)
 
#define INT16_MAX   (32767)
 
#define INT32_MAX   (2147483647)
 
#define UINT8_MAX   (255U)
 
#define UINT16_MAX   (65535U)
 
#define UINT32_MAX   (4294967295U)
 
#define yyconst
 
#define YY_NULL   0
 
#define YY_SC_TO_UI(c)   ((unsigned int) (unsigned char) c)
 
#define BEGIN   (yy_start) = 1 + 2 *
 
#define YY_START   (((yy_start) - 1) / 2)
 
#define YYSTATE   YY_START
 
#define YY_STATE_EOF(state)   (YY_END_OF_BUFFER + state + 1)
 
#define YY_NEW_FILE   pycodeYYrestart(pycodeYYin )
 
#define YY_END_OF_BUFFER_CHAR   0
 
#define YY_BUF_SIZE   16384
 
#define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
 
#define YY_TYPEDEF_YY_BUFFER_STATE
 
#define EOB_ACT_CONTINUE_SCAN   0
 
#define EOB_ACT_END_OF_FILE   1
 
#define EOB_ACT_LAST_MATCH   2
 
#define YY_LESS_LINENO(n)
 
#define yyless(n)
 
#define unput(c)   yyunput( c, (yytext_ptr) )
 
#define YY_TYPEDEF_YY_SIZE_T
 
#define YY_STRUCT_YY_BUFFER_STATE
 
#define YY_BUFFER_NEW   0
 
#define YY_BUFFER_NORMAL   1
 
#define YY_BUFFER_EOF_PENDING   2
 
#define YY_CURRENT_BUFFER
 
#define YY_CURRENT_BUFFER_LVALUE   (yy_buffer_stack)[(yy_buffer_stack_top)]
 
#define YY_FLUSH_BUFFER   pycodeYY_flush_buffer(YY_CURRENT_BUFFER )
 
#define yy_new_buffer   pycodeYY_create_buffer
 
#define yy_set_interactive(is_interactive)
 
#define yy_set_bol(at_bol)
 
#define YY_AT_BOL()   (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
 
#define pycodeYYwrap(n)   1
 
#define YY_SKIP_YYWRAP
 
#define yytext_ptr   pycodeYYtext
 
#define YY_DO_BEFORE_ACTION
 
#define YY_NUM_RULES   67
 
#define YY_END_OF_BUFFER   68
 
#define YY_TRAILING_MASK   0x2000
 
#define YY_TRAILING_HEAD_MASK   0x4000
 
#define REJECT
 
#define yymore()   yymore_used_but_not_detected
 
#define YY_MORE_ADJ   0
 
#define YY_RESTORE_YY_MORE_OFFSET
 
#define DBG_CTX(x)   do { } while(0)
 
#define YY_NO_INPUT   1
 
#define YY_NO_UNISTD_H   1
 
#define YY_INPUT(buf, result, max_size)   result=yyread(buf,max_size);
 
#define INITIAL   0
 
#define Body   1
 
#define FunctionDec   2
 
#define FunctionParams   3
 
#define ClassDec   4
 
#define ClassInheritance   5
 
#define Suite   6
 
#define SuiteCaptureIndent   7
 
#define SuiteStart   8
 
#define SuiteMaintain   9
 
#define SuiteContinuing   10
 
#define LongString   11
 
#define SingleQuoteString   12
 
#define DoubleQuoteString   13
 
#define TripleString   14
 
#define DocBlock   15
 
#define YY_EXTRA_TYPE   void *
 
#define YY_READ_BUF_SIZE   8192
 
#define ECHO   do { if (fwrite( pycodeYYtext, pycodeYYleng, 1, pycodeYYout )) {} } while (0)
 
#define yyterminate()   return YY_NULL
 
#define YY_START_STACK_INCR   25
 
#define YY_FATAL_ERROR(msg)   yy_fatal_error( msg )
 
#define YY_DECL_IS_OURS   1
 
#define YY_DECL   int pycodeYYlex (void)
 
#define YY_USER_ACTION
 
#define YY_BREAK   break;
 
#define YY_RULE_SETUP   YY_USER_ACTION
 
#define YY_EXIT_FAILURE   2
 
#define yyless(n)
 
#define YYTABLES_NAME   "yytables"
 

Typedefs

typedef signed char flex_int8_t
 
typedef short int flex_int16_t
 
typedef int flex_int32_t
 
typedef unsigned char flex_uint8_t
 
typedef unsigned short int flex_uint16_t
 
typedef unsigned int flex_uint32_t
 
typedef struct yy_buffer_stateYY_BUFFER_STATE
 
typedef size_t yy_size_t
 
typedef unsigned char YY_CHAR
 
typedef int yy_state_type
 

Functions

void pycodeYYrestart (FILE *input_file)
 
void pycodeYY_switch_to_buffer (YY_BUFFER_STATE new_buffer)
 
YY_BUFFER_STATE pycodeYY_create_buffer (FILE *file, int size)
 
void pycodeYY_delete_buffer (YY_BUFFER_STATE b)
 
void pycodeYY_flush_buffer (YY_BUFFER_STATE b)
 
void pycodeYYpush_buffer_state (YY_BUFFER_STATE new_buffer)
 
void pycodeYYpop_buffer_state (void)
 
static void pycodeYYensure_buffer_stack (void)
 
static void pycodeYY_load_buffer_state (void)
 
static void pycodeYY_init_buffer (YY_BUFFER_STATE b, FILE *file)
 
YY_BUFFER_STATE pycodeYY_scan_buffer (char *base, yy_size_t size)
 
YY_BUFFER_STATE pycodeYY_scan_string (yyconst char *yy_str)
 
YY_BUFFER_STATE pycodeYY_scan_bytes (yyconst char *bytes, int len)
 
void * pycodeYYalloc (yy_size_t)
 
void * pycodeYYrealloc (void *, yy_size_t)
 
void pycodeYYfree (void *)
 
static yy_state_type yy_get_previous_state (void)
 
static yy_state_type yy_try_NUL_trans (yy_state_type current_state)
 
static int yy_get_next_buffer (void)
 
static void yy_fatal_error (yyconst char msg[])
 
static void endFontClass ()
 
static void adjustScopesAndSuites (unsigned indentLength)
 
static int countLines ()
 
static void setCurrentDoc (const QCString &anchor)
 
static void addToSearchIndex (const char *text)
 
static ClassDefstripClassName (const char *s, Definition *d=g_currentDefinition)
 
static void startCodeLine ()
 
static void codify (const char *text)
 
static void endCodeLine ()
 
static void nextCodeLine ()
 
static void writeMultiLineCodeLink (CodeOutputInterface &ol, Definition *d, const char *text)
 
static void startFontClass (const char *s)
 
static void codifyLines (char *text)
 
static void codifyLines (const QCString &str)
 
static bool getLinkInScope (const QCString &c, const QCString &m, const char *memberText, CodeOutputInterface &ol, const char *text)
 
static bool getLink (const char *className, const char *memberName, CodeOutputInterface &ol, const char *text=0)
 
static void generateClassOrGlobalLink (CodeOutputInterface &ol, char *clName, bool typeOnly=FALSE)
 
static void generateFunctionLink (CodeOutputInterface &ol, char *funcName)
 
static bool findMemberLink (CodeOutputInterface &ol, Definition *sym, const char *symName)
 
static void findMemberLink (CodeOutputInterface &ol, char *symName)
 
static int yyread (char *buf, int max_size)
 
static int yy_init_globals (void)
 
int pycodeYYlex_destroy (void)
 
int pycodeYYget_debug (void)
 
void pycodeYYset_debug (int debug_flag)
 
YY_EXTRA_TYPE pycodeYYget_extra (void)
 
void pycodeYYset_extra (YY_EXTRA_TYPE user_defined)
 
FILE * pycodeYYget_in (void)
 
void pycodeYYset_in (FILE *in_str)
 
FILE * pycodeYYget_out (void)
 
void pycodeYYset_out (FILE *out_str)
 
int pycodeYYget_leng (void)
 
char * pycodeYYget_text (void)
 
int pycodeYYget_lineno (void)
 
void pycodeYYset_lineno (int line_number)
 
static void yyunput (int c, char *buf_ptr)
 
static void yy_push_state (int new_state)
 
static void yy_pop_state (void)
 
static int yy_top_state (void)
 
int pycodeYYlex (void)
 
 if (!(yy_init))
 
 while (1)
 
static void yyunput (int c, register char *yy_bp)
 
static void yy_fatal_error (yyconst char *msg)
 
void resetPythonCodeParserState ()
 
void parsePythonCode (CodeOutputInterface &od, const char *, const QCString &s, bool exBlock, const char *exName, FileDef *fd, int startLine, int endLine, bool, MemberDef *, bool, Definition *searchCtx, bool collectXRefs)
 

Variables

int pycodeYYleng
 
FILE * pycodeYYin = (FILE *) 0
 
FILE * pycodeYYout = (FILE *) 0
 
static size_t yy_buffer_stack_top = 0
 
static size_t yy_buffer_stack_max = 0
 
static YY_BUFFER_STATEyy_buffer_stack = 0
 
static char yy_hold_char
 
static int yy_n_chars
 
static char * yy_c_buf_p = (char *) 0
 
static int yy_init = 0
 
static int yy_start = 0
 
static int yy_did_buffer_switch_on_eof
 
int pycodeYYlineno = 1
 
char * pycodeYYtext
 
static yyconst flex_int16_t yy_acclist [1033]
 
static yyconst flex_int16_t yy_accept [541]
 
static yyconst flex_int32_t yy_ec [256]
 
static yyconst flex_int32_t yy_meta [44]
 
static yyconst flex_int16_t yy_base [574]
 
static yyconst flex_int16_t yy_def [574]
 
static yyconst flex_int16_t yy_nxt [1769]
 
static yyconst flex_int16_t yy_chk [1769]
 
int pycodeYY_flex_debug = 0
 
static yy_state_typeyy_state_buf =0
 
static yy_state_typeyy_state_ptr =0
 
static char * yy_full_match
 
static int yy_lp
 
static int yy_looking_for_trail_begin = 0
 
static int yy_full_lp
 
static int * yy_full_state
 
static ClassSDict g_codeClassSDict (17)
 
static QCString g_curClassName
 
static QStrList g_curClassBases
 
static CodeOutputInterfaceg_code
 
static const char * g_inputString
 the code fragment as text More...
 
static int g_inputPosition
 read offset during parsing More...
 
static const char * g_currentFontClass
 
static bool g_needsTermination
 
static Definitiong_searchCtx
 
static bool g_collectXRefs
 
static int g_inputLines
 number of line in the code fragment More...
 
static int g_yyLineNr
 current line number More...
 
static FileDefg_sourceFileDef
 
static Definitiong_currentDefinition
 
static MemberDefg_currentMemberDef
 
static bool g_includeCodeFragment
 
static QCString g_realScope
 
static int g_bodyCurlyCount
 
static bool g_searchingForBody
 
static QCString g_classScope
 
static int g_paramParens
 
static bool g_exampleBlock
 
static QCString g_exampleName
 
static QCString g_type
 
static QCString g_name
 
static bool g_doubleStringIsDoc
 
static bool g_doubleQuote
 
static bool g_noSuiteFound
 
static int g_stringContext
 
static QValueStack< uintg_indents
 Tracks indentation levels for scoping in python. More...
 
static QCString g_docBlock
 contents of all lines of a documentation block More...
 
static bool g_endComment
 
static PyVariableContext g_theVarContext
 
static PyCallContext g_theCallContext
 
static int yy_start_stack_ptr = 0
 
static int yy_start_stack_depth = 0
 
static int * yy_start_stack = NULL
 
 YY_DECL
 
register char * yy_cp
 
register char * yy_bp
 
register int yy_act
 

Macro Definition Documentation

#define BEGIN   (yy_start) = 1 + 2 *

Definition at line 144 of file pycode.cpp.

#define Body   1

Definition at line 2042 of file pycode.cpp.

#define ClassDec   4

Definition at line 2045 of file pycode.cpp.

#define ClassInheritance   5

Definition at line 2046 of file pycode.cpp.

#define DBG_CTX (   x)    do { } while(0)

Definition at line 1219 of file pycode.cpp.

#define DocBlock   15

Definition at line 2056 of file pycode.cpp.

#define DoubleQuoteString   13

Definition at line 2054 of file pycode.cpp.

#define ECHO   do { if (fwrite( pycodeYYtext, pycodeYYleng, 1, pycodeYYout )) {} } while (0)

Definition at line 2153 of file pycode.cpp.

#define EOB_ACT_CONTINUE_SCAN   0

Definition at line 179 of file pycode.cpp.

#define EOB_ACT_END_OF_FILE   1

Definition at line 180 of file pycode.cpp.

#define EOB_ACT_LAST_MATCH   2

Definition at line 181 of file pycode.cpp.

#define FLEX_BETA

Definition at line 33 of file pycode.cpp.

#define FLEX_SCANNER

Definition at line 28 of file pycode.cpp.

#define FLEXINT_H

Definition at line 49 of file pycode.cpp.

#define FunctionDec   2

Definition at line 2043 of file pycode.cpp.

#define FunctionParams   3

Definition at line 2044 of file pycode.cpp.

#define INITIAL   0

Definition at line 2041 of file pycode.cpp.

#define INT16_MAX   (32767)

Definition at line 92 of file pycode.cpp.

#define INT16_MIN   (-32767-1)

Definition at line 83 of file pycode.cpp.

#define INT32_MAX   (2147483647)

Definition at line 95 of file pycode.cpp.

#define INT32_MIN   (-2147483647-1)

Definition at line 86 of file pycode.cpp.

#define INT8_MAX   (127)

Definition at line 89 of file pycode.cpp.

#define INT8_MIN   (-128)

Definition at line 80 of file pycode.cpp.

#define LongString   11

Definition at line 2052 of file pycode.cpp.

#define pycodeYYwrap (   n)    1

Definition at line 354 of file pycode.cpp.

#define REJECT
Value:
{ \
*yy_cp = (yy_hold_char); /* undo effects of setting up pycodeYYtext */ \
yy_cp = (yy_full_match); /* restore poss. backed-over text */ \
(yy_lp) = (yy_full_lp); /* restore orig. accepting pos. */ \
(yy_state_ptr) = (yy_full_state); /* restore orig. state */ \
yy_current_state = *(yy_state_ptr); /* restore curr. state */ \
++(yy_lp); \
goto find_rule; \
}
static char * yy_full_match
Definition: pycode.cpp:1150
static yy_state_type * yy_state_ptr
Definition: pycode.cpp:1149
static int yy_lp
Definition: pycode.cpp:1151
static int * yy_full_state
Definition: pycode.cpp:1154
static char yy_hold_char
Definition: pycode.cpp:292
register char * yy_cp
Definition: pycode.cpp:2243
static int yy_full_lp
Definition: pycode.cpp:1153

Definition at line 1157 of file pycode.cpp.

#define SingleQuoteString   12

Definition at line 2053 of file pycode.cpp.

#define Suite   6

Definition at line 2047 of file pycode.cpp.

#define SuiteCaptureIndent   7

Definition at line 2048 of file pycode.cpp.

#define SuiteContinuing   10

Definition at line 2051 of file pycode.cpp.

#define SuiteMaintain   9

Definition at line 2050 of file pycode.cpp.

#define SuiteStart   8

Definition at line 2049 of file pycode.cpp.

#define TripleString   14

Definition at line 2055 of file pycode.cpp.

#define UINT16_MAX   (65535U)

Definition at line 101 of file pycode.cpp.

#define UINT32_MAX   (4294967295U)

Definition at line 104 of file pycode.cpp.

#define UINT8_MAX   (255U)

Definition at line 98 of file pycode.cpp.

#define unput (   c)    yyunput( c, (yytext_ptr) )

Definition at line 199 of file pycode.cpp.

#define YY_AT_BOL ( )    (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)

Definition at line 350 of file pycode.cpp.

#define YY_BREAK   break;

Definition at line 2232 of file pycode.cpp.

#define YY_BUF_SIZE   16384

Definition at line 163 of file pycode.cpp.

#define YY_BUFFER_EOF_PENDING   2

Definition at line 266 of file pycode.cpp.

#define YY_BUFFER_NEW   0

Definition at line 254 of file pycode.cpp.

#define YY_BUFFER_NORMAL   1

Definition at line 255 of file pycode.cpp.

#define yy_create_buffer   pycodeYY_create_buffer

Definition at line 9 of file pycode.cpp.

#define YY_CURRENT_BUFFER
Value:
: NULL)
static YY_BUFFER_STATE * yy_buffer_stack
Definition: pycode.cpp:274
static size_t yy_buffer_stack_top
Definition: pycode.cpp:272

Definition at line 282 of file pycode.cpp.

#define YY_CURRENT_BUFFER_LVALUE   (yy_buffer_stack)[(yy_buffer_stack_top)]

Definition at line 289 of file pycode.cpp.

#define YY_DECL   int pycodeYYlex (void)

Definition at line 2220 of file pycode.cpp.

#define YY_DECL_IS_OURS   1

Definition at line 2216 of file pycode.cpp.

#define yy_delete_buffer   pycodeYY_delete_buffer

Definition at line 10 of file pycode.cpp.

#define YY_DO_BEFORE_ACTION
Value:
pycodeYYleng = (size_t) (yy_cp - yy_bp); \
*yy_cp = '\0'; \
#define yytext_ptr
Definition: pycode.cpp:368
static char * yy_c_buf_p
Definition: pycode.cpp:297
register char * yy_bp
Definition: pycode.cpp:2243
static char yy_hold_char
Definition: pycode.cpp:292
register char * yy_cp
Definition: pycode.cpp:2243
int pycodeYYleng
Definition: pycode.cpp:294

Definition at line 378 of file pycode.cpp.

#define YY_END_OF_BUFFER   68

Definition at line 386 of file pycode.cpp.

#define YY_END_OF_BUFFER_CHAR   0

Definition at line 159 of file pycode.cpp.

#define YY_EXIT_FAILURE   2

Definition at line 3896 of file pycode.cpp.

#define YY_EXTRA_TYPE   void *

Definition at line 2067 of file pycode.cpp.

#define YY_FATAL_ERROR (   msg)    yy_fatal_error( msg )

Definition at line 2207 of file pycode.cpp.

#define yy_flex_debug   pycodeYY_flex_debug

Definition at line 11 of file pycode.cpp.

#define YY_FLEX_MAJOR_VERSION   2

Definition at line 29 of file pycode.cpp.

#define YY_FLEX_MINOR_VERSION   5

Definition at line 30 of file pycode.cpp.

#define YY_FLEX_SUBMINOR_VERSION   35

Definition at line 31 of file pycode.cpp.

#define yy_flush_buffer   pycodeYY_flush_buffer

Definition at line 13 of file pycode.cpp.

#define YY_FLUSH_BUFFER   pycodeYY_flush_buffer(YY_CURRENT_BUFFER )

Definition at line 318 of file pycode.cpp.

#define yy_init_buffer   pycodeYY_init_buffer

Definition at line 12 of file pycode.cpp.

#define YY_INPUT (   buf,
  result,
  max_size 
)    result=yyread(buf,max_size);

Definition at line 2011 of file pycode.cpp.

#define YY_INT_ALIGNED   short int

Definition at line 5 of file pycode.cpp.

#define YY_LESS_LINENO (   n)

Definition at line 183 of file pycode.cpp.

#define yy_load_buffer_state   pycodeYY_load_buffer_state

Definition at line 14 of file pycode.cpp.

#define YY_MORE_ADJ   0

Definition at line 1169 of file pycode.cpp.

#define yy_new_buffer   pycodeYY_create_buffer

Definition at line 328 of file pycode.cpp.

#define YY_NEW_FILE   pycodeYYrestart(pycodeYYin )

Definition at line 157 of file pycode.cpp.

#define YY_NO_INPUT   1

Definition at line 1221 of file pycode.cpp.

#define YY_NO_UNISTD_H   1

Definition at line 1222 of file pycode.cpp.

#define YY_NULL   0

Definition at line 131 of file pycode.cpp.

#define YY_NUM_RULES   67

Definition at line 385 of file pycode.cpp.

#define YY_READ_BUF_SIZE   8192

Definition at line 2145 of file pycode.cpp.

#define YY_RESTORE_YY_MORE_OFFSET

Definition at line 1170 of file pycode.cpp.

#define YY_RULE_SETUP   YY_USER_ACTION

Definition at line 2235 of file pycode.cpp.

#define YY_SC_TO_UI (   c)    ((unsigned int) (unsigned char) c)

Definition at line 138 of file pycode.cpp.

#define yy_set_bol (   at_bol)
Value:
{ \
pycodeYYensure_buffer_stack (); \
pycodeYY_create_buffer(pycodeYYin,YY_BUF_SIZE ); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
}
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
if(!(yy_init))
Definition: pycode.cpp:2251
FILE * pycodeYYin
Definition: pycode.cpp:359
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_BUF_SIZE
Definition: pycode.cpp:163

Definition at line 340 of file pycode.cpp.

#define yy_set_interactive (   is_interactive)
Value:
{ \
pycodeYYensure_buffer_stack (); \
pycodeYY_create_buffer(pycodeYYin,YY_BUF_SIZE ); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
}
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
if(!(yy_init))
Definition: pycode.cpp:2251
FILE * pycodeYYin
Definition: pycode.cpp:359
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_BUF_SIZE
Definition: pycode.cpp:163

Definition at line 330 of file pycode.cpp.

#define YY_SKIP_YYWRAP

Definition at line 355 of file pycode.cpp.

#define YY_START   (((yy_start) - 1) / 2)

Definition at line 150 of file pycode.cpp.

#define YY_START_STACK_INCR   25

Definition at line 2202 of file pycode.cpp.

#define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))

Definition at line 168 of file pycode.cpp.

#define YY_STATE_EOF (   state)    (YY_END_OF_BUFFER + state + 1)

Definition at line 154 of file pycode.cpp.

#define YY_STRUCT_YY_BUFFER_STATE

Definition at line 207 of file pycode.cpp.

#define yy_switch_to_buffer   pycodeYY_switch_to_buffer

Definition at line 15 of file pycode.cpp.

#define YY_TRAILING_HEAD_MASK   0x4000

Definition at line 1156 of file pycode.cpp.

#define YY_TRAILING_MASK   0x2000

Definition at line 1155 of file pycode.cpp.

#define YY_TYPEDEF_YY_BUFFER_STATE

Definition at line 171 of file pycode.cpp.

#define YY_TYPEDEF_YY_SIZE_T

Definition at line 202 of file pycode.cpp.

#define YY_USER_ACTION

Definition at line 2227 of file pycode.cpp.

#define yyalloc   pycodeYYalloc

Definition at line 24 of file pycode.cpp.

#define yyconst

Definition at line 127 of file pycode.cpp.

#define yyfree   pycodeYYfree

Definition at line 26 of file pycode.cpp.

#define yyin   pycodeYYin

Definition at line 16 of file pycode.cpp.

#define yyleng   pycodeYYleng

Definition at line 17 of file pycode.cpp.

#define yyless (   n)
Value:
do \
{ \
/* Undo effects of setting up pycodeYYtext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
(yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
YY_DO_BEFORE_ACTION; /* set up pycodeYYtext again */ \
} \
while ( 0 )
static char * yy_c_buf_p
Definition: pycode.cpp:297
register char * yy_bp
Definition: pycode.cpp:2243
static char yy_hold_char
Definition: pycode.cpp:292
std::void_t< T > n
#define YY_DO_BEFORE_ACTION
Definition: pycode.cpp:378
register char * yy_cp
Definition: pycode.cpp:2243
while(1)
Definition: pycode.cpp:2283
#define YY_RESTORE_YY_MORE_OFFSET
Definition: pycode.cpp:1170
#define YY_MORE_ADJ
Definition: pycode.cpp:1169

Definition at line 3908 of file pycode.cpp.

#define yyless (   n)
Value:
do \
{ \
/* Undo effects of setting up pycodeYYtext. */ \
int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\
(yy_c_buf_p) = pycodeYYtext + yyless_macro_arg; \
*(yy_c_buf_p) = '\0'; \
pycodeYYleng = yyless_macro_arg; \
} \
while ( 0 )
static char * yy_c_buf_p
Definition: pycode.cpp:297
char * pycodeYYtext
Definition: pycode.cpp:1171
static char yy_hold_char
Definition: pycode.cpp:292
std::void_t< T > n
while(1)
Definition: pycode.cpp:2283
int pycodeYYleng
Definition: pycode.cpp:294

Definition at line 3908 of file pycode.cpp.

#define yylex   pycodeYYlex

Definition at line 18 of file pycode.cpp.

#define yylineno   pycodeYYlineno

Definition at line 19 of file pycode.cpp.

#define yymore ( )    yymore_used_but_not_detected

Definition at line 1168 of file pycode.cpp.

#define yyout   pycodeYYout

Definition at line 20 of file pycode.cpp.

#define yyrealloc   pycodeYYrealloc

Definition at line 25 of file pycode.cpp.

#define yyrestart   pycodeYYrestart

Definition at line 21 of file pycode.cpp.

#define YYSTATE   YY_START

Definition at line 151 of file pycode.cpp.

#define YYTABLES_NAME   "yytables"

Definition at line 4114 of file pycode.cpp.

#define yyterminate ( )    return YY_NULL

Definition at line 2197 of file pycode.cpp.

#define yytext   pycodeYYtext

Definition at line 22 of file pycode.cpp.

#define yytext_ptr   pycodeYYtext

Definition at line 368 of file pycode.cpp.

#define yywrap   pycodeYYwrap

Definition at line 23 of file pycode.cpp.

Typedef Documentation

typedef short int flex_int16_t

Definition at line 71 of file pycode.cpp.

typedef int flex_int32_t

Definition at line 72 of file pycode.cpp.

typedef signed char flex_int8_t

Definition at line 70 of file pycode.cpp.

typedef unsigned short int flex_uint16_t

Definition at line 74 of file pycode.cpp.

typedef unsigned int flex_uint32_t

Definition at line 75 of file pycode.cpp.

typedef unsigned char flex_uint8_t

Definition at line 73 of file pycode.cpp.

Definition at line 172 of file pycode.cpp.

typedef unsigned char YY_CHAR

Definition at line 357 of file pycode.cpp.

typedef size_t yy_size_t

Definition at line 203 of file pycode.cpp.

typedef int yy_state_type

Definition at line 361 of file pycode.cpp.

Function Documentation

static void addToSearchIndex ( const char *  text)
static

Definition at line 1482 of file pycode.cpp.

1483 {
1485  {
1487  }
1488 }
const bool FALSE
Definition: qglobal.h:370
static SearchIndexIntf * searchIndex
Definition: doxygen.h:133
virtual void addWord(const char *word, bool hiPriority)=0
static void adjustScopesAndSuites ( unsigned  indentLength)
static

Examines current stack of white-space indentations; re-syncs the parser with the correct scope.

Definition at line 4137 of file pycode.cpp.

4138 {
4139  // States to pop
4140  if (!g_indents.isEmpty() && indentLength < g_indents.top())
4141  {
4142  while (!g_indents.isEmpty() && indentLength < g_indents.top())
4143  {
4144  // printf("Exited scope indent of [%d]\n", g_indents.top());
4145  g_indents.pop(); // Pop the old suite's indentation
4146 
4148  if (g_currentDefinition)
4150  }
4151  }
4152 
4153  // Are there any remaining indentation levels for suites?
4154  if (!g_indents.isEmpty())
4155  {
4156  BEGIN( Suite );
4157  }
4158  else
4159  {
4160  BEGIN( Body );
4161  }
4162 }
#define Suite
Definition: pycode.cpp:2047
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
virtual Definition * getOuterScope() const
#define BEGIN
Definition: pycode.cpp:144
#define Body
Definition: pycode.cpp:2042
static QValueStack< uint > g_indents
Tracks indentation levels for scoping in python.
Definition: pycode.cpp:1261
static void codify ( const char *  text)
static

Definition at line 1580 of file pycode.cpp.

1581 {
1582  g_code->codify(text);
1583 }
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
virtual void codify(const char *s)=0
static void codifyLines ( char *  text)
static

Definition at line 1666 of file pycode.cpp.

1667 {
1668  //printf("codifyLines(%d,\"%s\")\n",g_yyLineNr,text);
1669  char *p=text,*sp=p;
1670  char c;
1671  bool done=FALSE;
1672  const char * tmp_currentFontClass = g_currentFontClass;
1673  while (!done)
1674  {
1675  sp=p;
1676  while ((c=*p++) && c!='\n') { }
1677  if (c=='\n')
1678  {
1679  g_yyLineNr++;
1680  *(p-1)='\0';
1681  g_code->codify(sp);
1682  endCodeLine();
1684  {
1685  startCodeLine();
1686  }
1687  if (tmp_currentFontClass)
1688  {
1689  startFontClass(tmp_currentFontClass);
1690  }
1691  }
1692  else
1693  {
1694  g_code->codify(sp);
1695  done=TRUE;
1696  }
1697  }
1698 }
static int g_inputLines
number of line in the code fragment
Definition: pycode.cpp:1236
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
const bool FALSE
Definition: qglobal.h:370
static void startFontClass(const char *s)
Definition: pycode.cpp:1645
p
Definition: test.py:223
static void startCodeLine()
Definition: pycode.cpp:1525
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
virtual void codify(const char *s)=0
static const char * g_currentFontClass
Definition: pycode.cpp:1232
static void endCodeLine()
Definition: pycode.cpp:1585
const bool TRUE
Definition: qglobal.h:371
static void codifyLines ( const QCString str)
static

Definition at line 1700 of file pycode.cpp.

1701 {
1702  char *tmp= (char *)malloc(str.length()+1);
1703  qstrcpy(tmp, str);
1704  codifyLines(tmp);
1705  free(tmp);
1706 }
uint length() const
Definition: qcstring.h:195
string tmp
Definition: languages.py:63
Q_EXPORT char * qstrcpy(char *dst, const char *src)
Definition: qcstring.h:87
static void codifyLines(char *text)
Definition: pycode.cpp:1666
static int countLines ( )
static

counts the number of lines in the input

Definition at line 1448 of file pycode.cpp.

1449 {
1450  const char *p=g_inputString;
1451  char c;
1452  int count=1;
1453  while ((c=*p))
1454  {
1455  p++ ;
1456  if (c=='\n') count++;
1457  }
1458  if (p>g_inputString && *(p-1)!='\n')
1459  { // last line does not end with a \n, so we add an extra
1460  // line and explicitly terminate the line after parsing.
1461  count++,
1463  }
1464  return count;
1465 }
static const char * g_inputString
the code fragment as text
Definition: pycode.cpp:1230
p
Definition: test.py:223
const bool TRUE
Definition: qglobal.h:371
static bool g_needsTermination
Definition: pycode.cpp:1233
static void endCodeLine ( )
static

Definition at line 1585 of file pycode.cpp.

1586 {
1587  endFontClass();
1588  g_code->endCodeLine();
1589 }
static void endFontClass()
Definition: pycode.cpp:1657
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
virtual void endCodeLine()=0
static void endFontClass ( )
static

Definition at line 1657 of file pycode.cpp.

1658 {
1659  if (g_currentFontClass)
1660  {
1661  g_code->endFontClass();
1663  }
1664 }
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
virtual void endFontClass()=0
static const char * g_currentFontClass
Definition: pycode.cpp:1232
static bool findMemberLink ( CodeOutputInterface ol,
Definition sym,
const char *  symName 
)
static

Definition at line 1947 of file pycode.cpp.

1948 {
1949  //printf("sym %s outerScope=%s equal=%d\n",
1950  // sym->name().data(),sym->getOuterScope()->name().data(),
1951  // sym->getOuterScope()==g_currentDefinition);
1952 
1953  if (sym->getOuterScope() &&
1956  {
1957  ClassDef *cd = (ClassDef*)sym->getOuterScope();
1958  ClassDef *thisCd = (ClassDef *)g_currentDefinition;
1960  {
1962  {
1964  }
1965  }
1966  DBG_CTX((stderr,"cd=%s thisCd=%s\n",cd?cd->name().data():"<none>",thisCd?thisCd->name().data():"<none>"));
1967 
1968  // TODO: find the nearest base class in case cd is a base class of
1969  // thisCd
1970  if (cd==thisCd || (thisCd && thisCd->isBaseClass(cd,TRUE)))
1971  {
1972  writeMultiLineCodeLink(ol,sym,symName);
1973  return TRUE;
1974  }
1975  }
1976  return FALSE;
1977 }
static void writeMultiLineCodeLink(CodeOutputInterface &ol, Definition *d, const char *text)
Definition: pycode.cpp:1607
const bool FALSE
Definition: qglobal.h:370
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
bool isBaseClass(ClassDef *bcd, bool followInstances, int level=0)
Definition: classdef.cpp:2777
virtual DefType definitionType() const =0
const QCString & name() const
Definition: definition.h:114
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
const char * data() const
Definition: qcstring.h:207
virtual Definition * getOuterScope() const
void addDocCrossReference(MemberDef *src, MemberDef *dst)
Definition: util.cpp:8189
#define DBG_CTX(x)
Definition: pycode.cpp:1219
static bool g_collectXRefs
Definition: pycode.cpp:1235
const bool TRUE
Definition: qglobal.h:371
static void findMemberLink ( CodeOutputInterface ol,
char *  symName 
)
static

Definition at line 1979 of file pycode.cpp.

1980 {
1981  //printf("Member reference: %s scope=%s member=%s\n",
1982  // pycodeYYtext,
1983  // g_currentDefinition?g_currentDefinition->name().data():"<none>",
1984  // g_currentMemberDef?g_currentMemberDef->name().data():"<none>"
1985  // );
1986  if (g_currentDefinition)
1987  {
1988  DefinitionIntf *di = Doxygen::symbolMap->find(symName);
1989  if (di)
1990  {
1991  if (di->definitionType()==DefinitionIntf::TypeSymbolList) // multiple symbols
1992  {
1994  Definition *sym;
1995  for (dli.toFirst();(sym=dli.current());++dli)
1996  {
1997  if (findMemberLink(ol,sym,symName)) return;
1998  }
1999  }
2000  else // single symbol
2001  {
2002  if (findMemberLink(ol,(Definition*)di,symName)) return;
2003  }
2004  }
2005  }
2006  //printf("sym %s not found\n",&pycodeYYtext[5]);
2007  codify(symName);
2008 }
static bool findMemberLink(CodeOutputInterface &ol, Definition *sym, const char *symName)
Definition: pycode.cpp:1947
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
virtual DefType definitionType() const =0
static QDict< DefinitionIntf > * symbolMap
Definition: doxygen.h:134
static void codify(const char *text)
Definition: pycode.cpp:1580
static void generateClassOrGlobalLink ( CodeOutputInterface ol,
char *  clName,
bool  typeOnly = FALSE 
)
static

Class def that we may find

Member def that we may find

Definition at line 1777 of file pycode.cpp.

1779 {
1780  QCString className=clName;
1781 
1782  // Don't do anything for empty text
1783  if (className.isEmpty()) return;
1784 
1785  DBG_CTX((stderr,"generateClassOrGlobalLink(className=%s)\n",className.data()));
1786 
1787  ClassDef *cd=0,*lcd=0; /** Class def that we may find */
1788  MemberDef *md=0; /** Member def that we may find */
1789  //bool isLocal=FALSE;
1790 
1791  if ((lcd=g_theVarContext.findVariable(className))==0) // not a local variable
1792  {
1794  QCString scope = substitute(className,".","::");
1795 
1796  cd = getResolvedClass(d,g_sourceFileDef,substitute(className,".","::"),&md);
1797 
1798  DBG_CTX((stderr,"d=%s g_sourceFileDef=%s\n",
1799  d?d->displayName().data():"<null>",
1801  DBG_CTX((stderr,"is found as a type %s\n",cd?cd->name().data():"<null>"));
1802 
1803  if (cd==0 && md==0) // also see if it is variable or enum or enum value
1804  {
1805  NamespaceDef *nd = getResolvedNamespace(scope);
1806  if (nd)
1807  {
1808  writeMultiLineCodeLink(ol,nd,clName);
1809  addToSearchIndex(className);
1810  return;
1811  }
1812  else if (getLink(g_classScope,clName,ol,clName))
1813  {
1814  return;
1815  }
1816  }
1817  }
1818  else
1819  {
1821  {
1823  }
1824  //isLocal=TRUE;
1825  DBG_CTX((stderr,"is a local variable cd=%p!\n",cd));
1826  }
1827 
1828  if (cd && cd->isLinkable()) // is it a linkable class
1829  {
1830  writeMultiLineCodeLink(ol,cd,clName);
1831  addToSearchIndex(className);
1832  if (md)
1833  {
1835  md->getBodyDef() : md->getOuterScope();
1836  if (md->getGroupDef()) d = md->getGroupDef();
1837  if (d && d->isLinkable() && md->isLinkable() &&
1839  {
1841  }
1842  }
1843  }
1844  else // not a class, maybe a global member
1845  {
1846  int scopeEnd = className.findRev(".");
1847  if (scopeEnd!=-1 && !typeOnly) // name with explicit scope
1848  {
1849  QCString scope = substitute(className.left(scopeEnd),".","::");
1850  QCString locName = className.right(className.length()-scopeEnd-1);
1851  ClassDef *mcd = getClass(scope);
1852  DBG_CTX((stderr,"scope=%s locName=%s mcd=%p\n",scope.data(),locName.data(),mcd));
1853  if (mcd)
1854  {
1855  MemberDef *md = mcd->getMemberByName(locName);
1856  if (md)
1857  {
1859  writeMultiLineCodeLink(ol,md,clName);
1860  addToSearchIndex(className);
1862  md->getBodyDef() : md->getOuterScope();
1863  if (md->getGroupDef()) d = md->getGroupDef();
1864  if (d && d->isLinkable() && md->isLinkable() &&
1866  {
1868  }
1869  return;
1870  }
1871  }
1872  else // check namespace as well
1873  {
1874  NamespaceDef *mnd = getResolvedNamespace(scope);
1875  if (mnd)
1876  {
1877  MemberDef *md=mnd->getMemberByName(locName);
1878  if (md)
1879  {
1880  //printf("name=%s scope=%s\n",locName.data(),scope.data());
1882  writeMultiLineCodeLink(ol,md,clName);
1883  addToSearchIndex(className);
1885  md->getBodyDef() : md->getOuterScope();
1886  if (md->getGroupDef()) d = md->getGroupDef();
1887  if (d && d->isLinkable() && md->isLinkable() &&
1889  {
1891  }
1892  return;
1893  }
1894  }
1895  }
1896  }
1897 
1898  // nothing found, just write out the word
1899  codifyLines(clName);
1900  addToSearchIndex(clName);
1901  }
1902 }
static QCString g_classScope
Definition: pycode.cpp:1246
static void writeMultiLineCodeLink(CodeOutputInterface &ol, Definition *d, const char *text)
Definition: pycode.cpp:1607
virtual bool isLinkable() const =0
static QCString scope
Definition: declinfo.cpp:668
MemberDef * getMemberByName(const QCString &) const
bool isEmpty() const
Definition: qcstring.h:189
static PyCallContext g_theCallContext
Definition: pycode.cpp:1444
uint length() const
Definition: qcstring.h:195
FileDef * getBodyDef() const
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
static QCString className
Definition: declinfo.cpp:669
QCString left(uint len) const
Definition: qcstring.cpp:213
static bool getLink(const char *className, const char *memberName, CodeOutputInterface &ol, const char *text=0)
Definition: pycode.cpp:1752
MemberDef * getMemberByName(const QCString &) const
Definition: classdef.cpp:3968
virtual QCString displayName(bool includeScope=TRUE) const =0
ClassDef * findVariable(const QCString &name)
Definition: pycode.cpp:1352
int findRev(char c, int index=-1, bool cs=TRUE) const
Definition: qcstring.cpp:95
ClassDef * getClass(const char *n)
Definition: util.cpp:472
static NamespaceDef * globalScope
Definition: doxygen.h:128
const char * typeString() const
Definition: memberdef.cpp:4035
const QCString & name() const
Definition: definition.h:114
QCString right(uint len) const
Definition: qcstring.cpp:231
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
void setClass(ClassDef *cd)
Definition: pycode.cpp:1394
const char * data() const
Definition: qcstring.h:207
bool isLinkable() const
Definition: classdef.cpp:2729
static const ClassDef * dummyContext
Definition: pycode.cpp:1278
virtual Definition * getOuterScope() const
GroupDef * getGroupDef() const
Definition: memberdef.cpp:4095
void addDocCrossReference(MemberDef *src, MemberDef *dst)
Definition: util.cpp:8189
static void addToSearchIndex(const char *text)
Definition: pycode.cpp:1482
NamespaceDef * getResolvedNamespace(const char *name)
Definition: util.cpp:489
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
static void codifyLines(char *text)
Definition: pycode.cpp:1666
#define DBG_CTX(x)
Definition: pycode.cpp:1219
static bool g_collectXRefs
Definition: pycode.cpp:1235
ClassDef * getResolvedClass(Definition *scope, FileDef *fileScope, const char *n, MemberDef **pTypeDef, QCString *pTemplSpec, bool mayBeUnlinkable, bool mayBeHidden, QCString *pResolvedType)
Definition: util.cpp:1563
bool isLinkable() const
Definition: memberdef.cpp:1161
QCString substitute(const QCString &s, const QCString &src, const QCString &dst)
substitute all occurrences of src in s by dst
Definition: util.cpp:5088
static ClassDef * stripClassName(const char *s, Definition *d=g_currentDefinition)
Definition: pycode.cpp:1491
static PyVariableContext g_theVarContext
Definition: pycode.cpp:1372
static void generateFunctionLink ( CodeOutputInterface ol,
char *  funcName 
)
static

Definition at line 1911 of file pycode.cpp.

1912 {
1913  //CodeClassDef *ccd=0;
1914  ClassDef *ccd=0;
1915  QCString locScope=g_classScope.copy();
1916  QCString locFunc=removeRedundantWhiteSpace(funcName);
1917  DBG_CTX((stdout,"*** locScope=%s locFunc=%s\n",locScope.data(),locFunc.data()));
1918  int i=locFunc.findRev("::");
1919  if (i>0)
1920  {
1921  locScope=locFunc.left(i);
1922  locFunc=locFunc.right(locFunc.length()-i-2).stripWhiteSpace();
1923  }
1924  //printf("generateFunctionLink(%s) classScope=`%s'\n",locFunc.data(),locScope.data());
1925  if (!locScope.isEmpty() && (ccd=g_codeClassSDict[locScope]))
1926  {
1927  //printf("using classScope %s\n",g_classScope.data());
1928  if (ccd->baseClasses())
1929  {
1930  BaseClassListIterator bcli(*ccd->baseClasses());
1931  for ( ; bcli.current() ; ++bcli)
1932  {
1933  if (getLink(bcli.current()->classDef->name(),locFunc,ol,funcName))
1934  {
1935  return;
1936  }
1937  }
1938  }
1939  }
1940  if (!getLink(locScope,locFunc,ol,funcName))
1941  {
1942  generateClassOrGlobalLink(ol,funcName);
1943  }
1944  return;
1945 }
static QCString g_classScope
Definition: pycode.cpp:1246
bool isEmpty() const
Definition: qcstring.h:189
uint length() const
Definition: qcstring.h:195
static void generateClassOrGlobalLink(CodeOutputInterface &ol, char *clName, bool typeOnly=FALSE)
Definition: pycode.cpp:1777
static ClassSDict g_codeClassSDict(17)
QCString left(uint len) const
Definition: qcstring.cpp:213
static bool getLink(const char *className, const char *memberName, CodeOutputInterface &ol, const char *text=0)
Definition: pycode.cpp:1752
int findRev(char c, int index=-1, bool cs=TRUE) const
Definition: qcstring.cpp:95
QCString copy() const
Definition: qcstring.h:250
QCString right(uint len) const
Definition: qcstring.cpp:231
const char * data() const
Definition: qcstring.h:207
QCString removeRedundantWhiteSpace(const QCString &s)
Definition: util.cpp:1655
#define DBG_CTX(x)
Definition: pycode.cpp:1219
BaseClassList * baseClasses() const
Definition: classdef.cpp:4399
static bool getLink ( const char *  className,
const char *  memberName,
CodeOutputInterface ol,
const char *  text = 0 
)
static

Definition at line 1752 of file pycode.cpp.

1756 {
1757  QCString m=removeRedundantWhiteSpace(memberName);
1759  if (!getLinkInScope(c,m,memberName,ol,text))
1760  {
1761  if (!g_curClassName.isEmpty())
1762  {
1763  if (!c.isEmpty()) c.prepend("::");
1765  return getLinkInScope(c,m,memberName,ol,text);
1766  }
1767  return FALSE;
1768  }
1769  return TRUE;
1770 }
bool isEmpty() const
Definition: qcstring.h:189
const bool FALSE
Definition: qglobal.h:370
static QCString className
Definition: declinfo.cpp:669
static QCString g_curClassName
Definition: pycode.cpp:1225
QCString & prepend(const char *s)
Definition: qcstring.cpp:387
QCString removeRedundantWhiteSpace(const QCString &s)
Definition: util.cpp:1655
const bool TRUE
Definition: qglobal.h:371
static bool getLinkInScope(const QCString &c, const QCString &m, const char *memberText, CodeOutputInterface &ol, const char *text)
Definition: pycode.cpp:1708
static bool getLinkInScope ( const QCString c,
const QCString m,
const char *  memberText,
CodeOutputInterface ol,
const char *  text 
)
static

Definition at line 1708 of file pycode.cpp.

1714 {
1715  MemberDef *md;
1716  ClassDef *cd;
1717  FileDef *fd;
1718  NamespaceDef *nd;
1719  GroupDef *gd;
1720  //printf("Trying `%s'::`%s'\n",c.data(),m.data());
1721  if (getDefs(c,m,"()",md,cd,fd,nd,gd,FALSE,g_sourceFileDef) &&
1722  md->isLinkable())
1723  {
1724  //Definition *d=0;
1725  //if (cd) d=cd; else if (nd) d=nd; else if (fd) d=fd; else d=gd;
1726 
1728  md->getBodyDef() : md->getOuterScope();
1729  //printf("Found! d=%s\n",d?d->name().data():"<none>");
1730  if (md->getGroupDef()) d = md->getGroupDef();
1731  if (d && d->isLinkable())
1732  {
1734  //printf("g_currentDefinition=%p g_currentMemberDef=%p\n",
1735  // g_currentDefinition,g_currentMemberDef);
1736 
1739  {
1741  }
1742  //printf("d->getReference()=`%s' d->getOutputBase()=`%s' name=`%s' member name=`%s'\n",d->getReference().data(),d->getOutputFileBase().data(),d->name().data(),md->name().data());
1743 
1744  writeMultiLineCodeLink(ol,md, text ? text : memberText);
1745  addToSearchIndex(text ? text : memberText);
1746  return TRUE;
1747  }
1748  }
1749  return FALSE;
1750 }
static void writeMultiLineCodeLink(CodeOutputInterface &ol, Definition *d, const char *text)
Definition: pycode.cpp:1607
virtual bool isLinkable() const =0
static PyCallContext g_theCallContext
Definition: pycode.cpp:1444
FileDef * getBodyDef() const
const bool FALSE
Definition: qglobal.h:370
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
static NamespaceDef * globalScope
Definition: doxygen.h:128
const char * typeString() const
Definition: memberdef.cpp:4035
bool getDefs(const QCString &scName, const QCString &mbName, const char *args, MemberDef *&md, ClassDef *&cd, FileDef *&fd, NamespaceDef *&nd, GroupDef *&gd, bool forceEmptyScope, FileDef *currentFile, bool checkCV, const char *forceTagFile)
Definition: util.cpp:3932
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
void setClass(ClassDef *cd)
Definition: pycode.cpp:1394
virtual Definition * getOuterScope() const
GroupDef * getGroupDef() const
Definition: memberdef.cpp:4095
void addDocCrossReference(MemberDef *src, MemberDef *dst)
Definition: util.cpp:8189
static void addToSearchIndex(const char *text)
Definition: pycode.cpp:1482
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
static bool g_collectXRefs
Definition: pycode.cpp:1235
bool isLinkable() const
Definition: memberdef.cpp:1161
const bool TRUE
Definition: qglobal.h:371
static ClassDef * stripClassName(const char *s, Definition *d=g_currentDefinition)
Definition: pycode.cpp:1491
if ( yy_init)

Definition at line 2251 of file pycode.cpp.

2252  {
2253  (yy_init) = 1;
2254 
2255 #ifdef YY_USER_INIT
2256  YY_USER_INIT;
2257 #endif
2258 
2259  /* Create the reject buffer large enough to save one state per allowed character. */
2260  if ( ! (yy_state_buf) )
2262  if ( ! (yy_state_buf) )
2263  YY_FATAL_ERROR( "out of dynamic memory in pycodeYYlex()" );
2264 
2265  if ( ! (yy_start) )
2266  (yy_start) = 1; /* first start state */
2267 
2268  if ( ! pycodeYYin )
2269  pycodeYYin = stdin;
2270 
2271  if ( ! pycodeYYout )
2272  pycodeYYout = stdout;
2273 
2274  if ( ! YY_CURRENT_BUFFER ) {
2278  }
2279 
2281  }
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
YY_BUFFER_STATE pycodeYY_create_buffer(FILE *file, int size)
Definition: pycode.cpp:3576
FILE * pycodeYYout
Definition: pycode.cpp:359
int yy_state_type
Definition: code.cpp:361
static int yy_init
Definition: pycode.cpp:298
static void pycodeYYensure_buffer_stack(void)
Definition: pycode.cpp:3729
FILE * pycodeYYin
Definition: pycode.cpp:359
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
#define YY_BUF_SIZE
Definition: pycode.cpp:163
#define YY_STATE_BUF_SIZE
Definition: pycode.cpp:168
static int yy_start
Definition: pycode.cpp:299
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
static yy_state_type * yy_state_buf
Definition: pycode.cpp:1149
static void nextCodeLine ( )
static

Definition at line 1591 of file pycode.cpp.

1592 {
1593  const char *fc = g_currentFontClass;
1594  endCodeLine();
1595  if (g_yyLineNr<g_inputLines)
1596  {
1597  g_currentFontClass = fc;
1598  startCodeLine();
1599  }
1600 }
static int g_inputLines
number of line in the code fragment
Definition: pycode.cpp:1236
static void startCodeLine()
Definition: pycode.cpp:1525
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
static const char * g_currentFontClass
Definition: pycode.cpp:1232
static void endCodeLine()
Definition: pycode.cpp:1585
void parsePythonCode ( CodeOutputInterface od,
const char *  ,
const QCString s,
bool  exBlock,
const char *  exName,
FileDef fd,
int  startLine,
int  endLine,
bool  ,
MemberDef ,
bool  ,
Definition searchCtx,
bool  collectXRefs 
)

Definition at line 4164 of file pycode.cpp.

4168 {
4169 
4170  //printf("***parseCode()\n");
4171 
4172  //--------------------------------------
4173  if (s.isEmpty()) return;
4174  printlex(pycodeYY_flex_debug, TRUE, __FILE__, fd ? fd->fileName().data(): NULL);
4176  g_code = &od;
4177  g_inputString = s;
4178  g_inputPosition = 0;
4179  g_currentFontClass = 0;
4181  g_searchCtx=searchCtx;
4183  if (endLine!=-1)
4184  g_inputLines = endLine+1;
4185  else
4187 
4188  if (startLine!=-1)
4189  g_yyLineNr = startLine;
4190  else
4191  g_yyLineNr = 1;
4192 
4193  g_exampleBlock = exBlock;
4194  g_exampleName = exName;
4195  g_sourceFileDef = fd;
4196 
4197  bool cleanupSourceDef = FALSE;
4198  if (fd==0)
4199  {
4200  // create a dummy filedef for the example
4201  g_sourceFileDef = new FileDef("",(exName?exName:"generated"));
4202  cleanupSourceDef = TRUE;
4203  }
4204  if (g_sourceFileDef)
4205  {
4206  setCurrentDoc("l00001");
4207  }
4208 
4209  // Starts line 1 on the output
4210  startCodeLine();
4211 
4213 
4214  pycodeYYlex();
4215 
4216  if (!g_indents.isEmpty())
4217  {
4218  // printf("Exited pysourceparser in inconsistent state!\n");
4219  }
4220 
4221  if (g_needsTermination)
4222  {
4223  endCodeLine();
4224  }
4225  if (fd)
4226  {
4228  }
4229  if (cleanupSourceDef)
4230  {
4231  // delete the temporary file definition used for this example
4232  delete g_sourceFileDef;
4233  g_sourceFileDef=0;
4234  }
4235  printlex(pycodeYY_flex_debug, FALSE, __FILE__, fd ? fd->fileName().data(): NULL);
4236  return;
4237 }
static int g_inputLines
number of line in the code fragment
Definition: pycode.cpp:1236
bool isEmpty() const
Definition: qcstring.h:189
void printlex(int dbg, bool enter, const char *lexName, const char *fileName)
Definition: message.cpp:242
static const char * g_inputString
the code fragment as text
Definition: pycode.cpp:1230
static int countLines()
Definition: pycode.cpp:1448
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
static Definition * g_searchCtx
Definition: pycode.cpp:1234
const bool FALSE
Definition: qglobal.h:370
static bool g_exampleBlock
Definition: pycode.cpp:1250
void clearTooltips()
Definition: tooltip.cpp:54
void pycodeYYrestart(FILE *input_file)
Definition: pycode.cpp:3514
int pycodeYY_flex_debug
Definition: pycode.cpp:1147
static void setCurrentDoc(const QCString &anchor)
Definition: pycode.cpp:1467
static int g_inputPosition
read offset during parsing
Definition: pycode.cpp:1231
FILE * pycodeYYin
Definition: pycode.cpp:359
const char * data() const
Definition: qcstring.h:207
static void startCodeLine()
Definition: pycode.cpp:1525
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
void writeTooltips(CodeOutputInterface &ol)
Definition: tooltip.cpp:93
int pycodeYYlex(void)
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
static TooltipManager * instance()
Definition: tooltip.cpp:45
QCString fileName() const
Definition: filedef.h:81
static const char * g_currentFontClass
Definition: pycode.cpp:1232
static void endCodeLine()
Definition: pycode.cpp:1585
static QCString g_exampleName
Definition: pycode.cpp:1251
static bool g_collectXRefs
Definition: pycode.cpp:1235
static QCString * s
Definition: config.cpp:1042
static QValueStack< uint > g_indents
Tracks indentation levels for scoping in python.
Definition: pycode.cpp:1261
const bool TRUE
Definition: qglobal.h:371
bool collectXRefs
static bool g_needsTermination
Definition: pycode.cpp:1233
YY_BUFFER_STATE pycodeYY_create_buffer ( FILE *  file,
int  size 
)

Allocate and initialize an input buffer state.

Parameters
fileA readable stream.
sizeThe character buffer size in bytes. When in doubt, use YY_BUF_SIZE.
Returns
the allocated buffer state.

Definition at line 3576 of file pycode.cpp.

3577 {
3579 
3580  b = (YY_BUFFER_STATE) pycodeYYalloc(sizeof( struct yy_buffer_state ) );
3581  if ( ! b )
3582  YY_FATAL_ERROR( "out of dynamic memory in pycodeYY_create_buffer()" );
3583 
3584  b->yy_buf_size = size;
3585 
3586  /* yy_ch_buf has to be 2 characters longer than the size given because
3587  * we need to put in 2 end-of-buffer characters.
3588  */
3589  b->yy_ch_buf = (char *) pycodeYYalloc(b->yy_buf_size + 2 );
3590  if ( ! b->yy_ch_buf )
3591  YY_FATAL_ERROR( "out of dynamic memory in pycodeYY_create_buffer()" );
3592 
3593  b->yy_is_our_buffer = 1;
3594 
3596 
3597  return b;
3598 }
yy_size_t yy_buf_size
Definition: code.cpp:218
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Definition: StdUtils.h:92
char * yy_ch_buf
Definition: code.cpp:212
int yy_is_our_buffer
Definition: code.cpp:229
struct yy_buffer_state * YY_BUFFER_STATE
Definition: pycode.cpp:172
static void pycodeYY_init_buffer(YY_BUFFER_STATE b, FILE *file)
Definition: pycode.cpp:3623
static bool * b
Definition: config.cpp:1043
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
void pycodeYY_delete_buffer ( YY_BUFFER_STATE  b)

Destroy the buffer.

Parameters
ba buffer created with pycodeYY_create_buffer()

Definition at line 3604 of file pycode.cpp.

3605 {
3606 
3607  if ( ! b )
3608  return;
3609 
3610  if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
3612 
3613  if ( b->yy_is_our_buffer )
3614  pycodeYYfree((void *) b->yy_ch_buf );
3615 
3616  pycodeYYfree((void *) b );
3617 }
void pycodeYYfree(void *)
Definition: pycode.cpp:4109
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
char * yy_ch_buf
Definition: code.cpp:212
int yy_is_our_buffer
Definition: code.cpp:229
struct yy_buffer_state * YY_BUFFER_STATE
Definition: pycode.cpp:172
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
void pycodeYY_flush_buffer ( YY_BUFFER_STATE  b)

Discard all buffered characters. On the next scan, YY_INPUT will be called.

Parameters
bthe buffer state to be flushed, usually YY_CURRENT_BUFFER.

Definition at line 3651 of file pycode.cpp.

3652 {
3653  if ( ! b )
3654  return;
3655 
3656  b->yy_n_chars = 0;
3657 
3658  /* We always need two end-of-buffer characters. The first causes
3659  * a transition to the end-of-buffer state. The second causes
3660  * a jam in that state.
3661  */
3664 
3665  b->yy_buf_pos = &b->yy_ch_buf[0];
3666 
3667  b->yy_at_bol = 1;
3669 
3670  if ( b == YY_CURRENT_BUFFER )
3672 }
char * yy_buf_pos
Definition: code.cpp:213
int yy_n_chars
Definition: code.cpp:223
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
#define YY_END_OF_BUFFER_CHAR
Definition: pycode.cpp:159
char * yy_ch_buf
Definition: code.cpp:212
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
int yy_buffer_status
Definition: code.cpp:252
#define YY_BUFFER_NEW
Definition: pycode.cpp:254
static void pycodeYY_init_buffer ( YY_BUFFER_STATE  b,
FILE *  file 
)
static

Definition at line 3623 of file pycode.cpp.

3625 {
3626  int oerrno = errno;
3627 
3629 
3630  b->yy_input_file = file;
3631  b->yy_fill_buffer = 1;
3632 
3633  /* If b is the current buffer, then pycodeYY_init_buffer was _probably_
3634  * called from pycodeYYrestart() or through yy_get_next_buffer.
3635  * In that case, we don't want to reset the lineno or column.
3636  */
3637  if (b != YY_CURRENT_BUFFER){
3638  b->yy_bs_lineno = 1;
3639  b->yy_bs_column = 0;
3640  }
3641 
3642  b->yy_is_interactive = 0;
3643 
3644  errno = oerrno;
3645 }
FILE * yy_input_file
Definition: code.cpp:210
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
int yy_fill_buffer
Definition: code.cpp:250
int yy_bs_lineno
Definition: code.cpp:244
int errno
Contains the last error code.
Definition: structcmd.h:53
int yy_bs_column
Definition: code.cpp:245
void pycodeYY_flush_buffer(YY_BUFFER_STATE b)
Definition: pycode.cpp:3651
int yy_is_interactive
Definition: code.cpp:236
static void pycodeYY_load_buffer_state ( void  )
static

Definition at line 3562 of file pycode.cpp.

3563 {
3564  (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3565  (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
3566  pycodeYYin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
3567  (yy_hold_char) = *(yy_c_buf_p);
3568 }
static int yy_n_chars
Definition: pycode.cpp:293
#define yytext_ptr
Definition: pycode.cpp:368
static char * yy_c_buf_p
Definition: pycode.cpp:297
static char yy_hold_char
Definition: pycode.cpp:292
FILE * pycodeYYin
Definition: pycode.cpp:359
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
YY_BUFFER_STATE pycodeYY_scan_buffer ( char *  base,
yy_size_t  size 
)

Setup the input buffer state to scan directly from a user-specified character buffer.

Parameters
basethe character buffer
sizethe size in bytes of the character buffer
Returns
the newly allocated buffer state object.

Definition at line 3778 of file pycode.cpp.

3779 {
3781 
3782  if ( size < 2 ||
3785  /* They forgot to leave room for the EOB's. */
3786  return 0;
3787 
3788  b = (YY_BUFFER_STATE) pycodeYYalloc(sizeof( struct yy_buffer_state ) );
3789  if ( ! b )
3790  YY_FATAL_ERROR( "out of dynamic memory in pycodeYY_scan_buffer()" );
3791 
3792  b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
3793  b->yy_buf_pos = b->yy_ch_buf = base;
3794  b->yy_is_our_buffer = 0;
3795  b->yy_input_file = 0;
3796  b->yy_n_chars = b->yy_buf_size;
3797  b->yy_is_interactive = 0;
3798  b->yy_at_bol = 1;
3799  b->yy_fill_buffer = 0;
3801 
3803 
3804  return b;
3805 }
char * yy_buf_pos
Definition: code.cpp:213
FILE * yy_input_file
Definition: code.cpp:210
void pycodeYY_switch_to_buffer(YY_BUFFER_STATE new_buffer)
Definition: pycode.cpp:3531
int yy_n_chars
Definition: code.cpp:223
int yy_fill_buffer
Definition: code.cpp:250
yy_size_t yy_buf_size
Definition: code.cpp:218
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Definition: StdUtils.h:92
#define YY_END_OF_BUFFER_CHAR
Definition: pycode.cpp:159
char * yy_ch_buf
Definition: code.cpp:212
int yy_is_our_buffer
Definition: code.cpp:229
struct yy_buffer_state * YY_BUFFER_STATE
Definition: pycode.cpp:172
static bool * b
Definition: config.cpp:1043
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
int yy_is_interactive
Definition: code.cpp:236
int yy_buffer_status
Definition: code.cpp:252
#define YY_BUFFER_NEW
Definition: pycode.cpp:254
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
YY_BUFFER_STATE pycodeYY_scan_bytes ( yyconst char *  yybytes,
int  _yybytes_len 
)

Setup the input buffer state to scan the given bytes. The next call to pycodeYYlex() will scan from a copy of bytes.

Parameters
bytesthe byte buffer to scan
lenthe number of bytes in the buffer pointed to by bytes.
Returns
the newly allocated buffer state object.

Definition at line 3828 of file pycode.cpp.

3829 {
3831  char *buf;
3832  yy_size_t n;
3833  int i;
3834 
3835  /* Get memory for full buffer, including space for trailing EOB's. */
3836  n = _yybytes_len + 2;
3837  buf = (char *) pycodeYYalloc(n );
3838  if ( ! buf )
3839  YY_FATAL_ERROR( "out of dynamic memory in pycodeYY_scan_bytes()" );
3840 
3841  for ( i = 0; i < _yybytes_len; ++i )
3842  buf[i] = yybytes[i];
3843 
3844  buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
3845 
3846  b = pycodeYY_scan_buffer(buf,n );
3847  if ( ! b )
3848  YY_FATAL_ERROR( "bad buffer in pycodeYY_scan_bytes()" );
3849 
3850  /* It's okay to grow etc. this buffer, and we should throw it
3851  * away when we're done.
3852  */
3853  b->yy_is_our_buffer = 1;
3854 
3855  return b;
3856 }
YY_BUFFER_STATE pycodeYY_scan_buffer(char *base, yy_size_t size)
Definition: pycode.cpp:3778
#define YY_END_OF_BUFFER_CHAR
Definition: pycode.cpp:159
std::void_t< T > n
int yy_is_our_buffer
Definition: code.cpp:229
static bool * b
Definition: config.cpp:1043
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
size_t yy_size_t
Definition: code.cpp:203
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
YY_BUFFER_STATE pycodeYY_scan_string ( yyconst char *  yystr)

Setup the input buffer state to scan a string. The next call to pycodeYYlex() will scan from a copy of str.

Parameters
yystra NUL-terminated string to scan
Returns
the newly allocated buffer state object.
Note
If you want to scan bytes that may contain NUL values, then use pycodeYY_scan_bytes() instead.

Definition at line 3815 of file pycode.cpp.

3816 {
3817 
3818  return pycodeYY_scan_bytes(yystr,strlen(yystr) );
3819 }
YY_BUFFER_STATE pycodeYY_scan_bytes(yyconst char *bytes, int len)
Definition: pycode.cpp:3828
void pycodeYY_switch_to_buffer ( YY_BUFFER_STATE  new_buffer)

Switch to a different input buffer.

Parameters
new_bufferThe new input buffer.

Definition at line 3531 of file pycode.cpp.

3532 {
3533 
3534  /* TODO. We should be able to replace this entire function body
3535  * with
3536  * pycodeYYpop_buffer_state();
3537  * pycodeYYpush_buffer_state(new_buffer);
3538  */
3540  if ( YY_CURRENT_BUFFER == new_buffer )
3541  return;
3542 
3543  if ( YY_CURRENT_BUFFER )
3544  {
3545  /* Flush out information for old buffer. */
3546  *(yy_c_buf_p) = (yy_hold_char);
3547  YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3548  YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3549  }
3550 
3551  YY_CURRENT_BUFFER_LVALUE = new_buffer;
3553 
3554  /* We don't actually know whether we did this switch during
3555  * EOF (pycodeYYwrap()) processing, but the only time this flag
3556  * is looked at is after pycodeYYwrap() is called, so it's safe
3557  * to go ahead and always set it.
3558  */
3560 }
static int yy_n_chars
Definition: pycode.cpp:293
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
static int yy_did_buffer_switch_on_eof
Definition: pycode.cpp:304
static char * yy_c_buf_p
Definition: pycode.cpp:297
static char yy_hold_char
Definition: pycode.cpp:292
static void pycodeYYensure_buffer_stack(void)
Definition: pycode.cpp:3729
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
void * pycodeYYalloc ( yy_size_t  size)

Definition at line 4092 of file pycode.cpp.

4093 {
4094  return (void *) malloc( size );
4095 }
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Definition: StdUtils.h:92
static void pycodeYYensure_buffer_stack ( void  )
static

Definition at line 3729 of file pycode.cpp.

3730 {
3731  int num_to_alloc;
3732 
3733  if (!(yy_buffer_stack)) {
3734 
3735  /* First allocation is just for 2 elements, since we don't know if this
3736  * scanner will even need a stack. We use 2 instead of 1 to avoid an
3737  * immediate realloc on the next call.
3738  */
3739  num_to_alloc = 1;
3741  (num_to_alloc * sizeof(struct yy_buffer_state*)
3742  );
3743  if ( ! (yy_buffer_stack) )
3744  YY_FATAL_ERROR( "out of dynamic memory in pycodeYYensure_buffer_stack()" );
3745 
3746  memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
3747 
3748  (yy_buffer_stack_max) = num_to_alloc;
3749  (yy_buffer_stack_top) = 0;
3750  return;
3751  }
3752 
3753  if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
3754 
3755  /* Increase the buffer to prepare for a possible push. */
3756  int grow_size = 8 /* arbitrary grow size */;
3757 
3758  num_to_alloc = (yy_buffer_stack_max) + grow_size;
3760  ((yy_buffer_stack),
3761  num_to_alloc * sizeof(struct yy_buffer_state*)
3762  );
3763  if ( ! (yy_buffer_stack) )
3764  YY_FATAL_ERROR( "out of dynamic memory in pycodeYYensure_buffer_stack()" );
3765 
3766  /* zero only the new slots.*/
3767  memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*));
3768  (yy_buffer_stack_max) = num_to_alloc;
3769  }
3770 }
static YY_BUFFER_STATE * yy_buffer_stack
Definition: pycode.cpp:274
void * pycodeYYrealloc(void *, yy_size_t)
Definition: pycode.cpp:4097
static size_t yy_buffer_stack_max
Definition: pycode.cpp:273
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
static size_t yy_buffer_stack_top
Definition: pycode.cpp:272
void pycodeYYfree ( void *  ptr)

Definition at line 4109 of file pycode.cpp.

4110 {
4111  free( (char *) ptr ); /* see pycodeYYrealloc() for (char *) cast */
4112 }
int pycodeYYget_debug ( void  )

Definition at line 3992 of file pycode.cpp.

3993 {
3994  return pycodeYY_flex_debug;
3995 }
int pycodeYY_flex_debug
Definition: pycode.cpp:1147
YY_EXTRA_TYPE pycodeYYget_extra ( void  )
FILE * pycodeYYget_in ( void  )

Get the input stream.

Definition at line 3936 of file pycode.cpp.

3937 {
3938  return pycodeYYin;
3939 }
FILE * pycodeYYin
Definition: pycode.cpp:359
int pycodeYYget_leng ( void  )

Get the length of the current token.

Definition at line 3952 of file pycode.cpp.

3953 {
3954  return pycodeYYleng;
3955 }
int pycodeYYleng
Definition: pycode.cpp:294
int pycodeYYget_lineno ( void  )

Get the current line number.

Definition at line 3927 of file pycode.cpp.

3928 {
3929 
3930  return pycodeYYlineno;
3931 }
int pycodeYYlineno
Definition: pycode.cpp:365
FILE * pycodeYYget_out ( void  )

Get the output stream.

Definition at line 3944 of file pycode.cpp.

3945 {
3946  return pycodeYYout;
3947 }
FILE * pycodeYYout
Definition: pycode.cpp:359
char * pycodeYYget_text ( void  )

Get the current token.

Definition at line 3961 of file pycode.cpp.

3962 {
3963  return pycodeYYtext;
3964 }
char * pycodeYYtext
Definition: pycode.cpp:1171
int pycodeYYlex ( void  )
int pycodeYYlex_destroy ( void  )

Definition at line 4040 of file pycode.cpp.

4041 {
4042 
4043  /* Pop the buffer stack, destroying each element. */
4044  while(YY_CURRENT_BUFFER){
4046  YY_CURRENT_BUFFER_LVALUE = NULL;
4048  }
4049 
4050  /* Destroy the stack itself. */
4052  (yy_buffer_stack) = NULL;
4053 
4054  /* Destroy the start condition stack. */
4056  (yy_start_stack) = NULL;
4057 
4058  pycodeYYfree ( (yy_state_buf) );
4059  (yy_state_buf) = NULL;
4060 
4061  /* Reset the globals. This is important in a non-reentrant scanner so the next time
4062  * pycodeYYlex() is called, initialization will occur. */
4063  yy_init_globals( );
4064 
4065  return 0;
4066 }
void pycodeYYfree(void *)
Definition: pycode.cpp:4109
void pycodeYYpop_buffer_state(void)
Definition: pycode.cpp:3710
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
static int * yy_start_stack
Definition: pycode.cpp:2135
static YY_BUFFER_STATE * yy_buffer_stack
Definition: pycode.cpp:274
void pycodeYY_delete_buffer(YY_BUFFER_STATE b)
Definition: pycode.cpp:3604
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
static int yy_init_globals(void)
Definition: pycode.cpp:4002
static yy_state_type * yy_state_buf
Definition: pycode.cpp:1149
void pycodeYYpop_buffer_state ( void  )

Removes and deletes the top of the stack, if present. The next element becomes the new top.

Definition at line 3710 of file pycode.cpp.

3711 {
3712  if (!YY_CURRENT_BUFFER)
3713  return;
3714 
3716  YY_CURRENT_BUFFER_LVALUE = NULL;
3717  if ((yy_buffer_stack_top) > 0)
3718  --(yy_buffer_stack_top);
3719 
3720  if (YY_CURRENT_BUFFER) {
3723  }
3724 }
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
static int yy_did_buffer_switch_on_eof
Definition: pycode.cpp:304
void pycodeYY_delete_buffer(YY_BUFFER_STATE b)
Definition: pycode.cpp:3604
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
static size_t yy_buffer_stack_top
Definition: pycode.cpp:272
void pycodeYYpush_buffer_state ( YY_BUFFER_STATE  new_buffer)

Pushes the new state onto the stack. The new state becomes the current state. This function will allocate the stack if necessary.

Parameters
new_bufferThe new state.

Definition at line 3680 of file pycode.cpp.

3681 {
3682  if (new_buffer == NULL)
3683  return;
3684 
3686 
3687  /* This block is copied from pycodeYY_switch_to_buffer. */
3688  if ( YY_CURRENT_BUFFER )
3689  {
3690  /* Flush out information for old buffer. */
3691  *(yy_c_buf_p) = (yy_hold_char);
3692  YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p);
3693  YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3694  }
3695 
3696  /* Only push if top exists. Otherwise, replace top. */
3697  if (YY_CURRENT_BUFFER)
3698  (yy_buffer_stack_top)++;
3699  YY_CURRENT_BUFFER_LVALUE = new_buffer;
3700 
3701  /* copied from pycodeYY_switch_to_buffer. */
3704 }
static int yy_n_chars
Definition: pycode.cpp:293
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
static int yy_did_buffer_switch_on_eof
Definition: pycode.cpp:304
static char * yy_c_buf_p
Definition: pycode.cpp:297
static char yy_hold_char
Definition: pycode.cpp:292
static void pycodeYYensure_buffer_stack(void)
Definition: pycode.cpp:3729
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
static size_t yy_buffer_stack_top
Definition: pycode.cpp:272
void * pycodeYYrealloc ( void *  ptr,
yy_size_t  size 
)

Definition at line 4097 of file pycode.cpp.

4098 {
4099  /* The cast to (char *) in the following accommodates both
4100  * implementations that use char* generic pointers, and those
4101  * that use void* generic pointers. It works with the latter
4102  * because both ANSI C and C++ allow castless assignment from
4103  * any pointer type to void*, and deal with argument conversions
4104  * as though doing an assignment.
4105  */
4106  return (void *) realloc( (char *) ptr, size );
4107 }
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Definition: StdUtils.h:92
void pycodeYYrestart ( FILE *  input_file)

Immediately switch to a different input stream.

Parameters
input_fileA readable stream.
Note
This function does not reset the start condition to INITIAL .

Definition at line 3514 of file pycode.cpp.

3515 {
3516 
3517  if ( ! YY_CURRENT_BUFFER ){
3521  }
3522 
3525 }
#define YY_CURRENT_BUFFER
Definition: pycode.cpp:282
YY_BUFFER_STATE pycodeYY_create_buffer(FILE *file, int size)
Definition: pycode.cpp:3576
static void pycodeYYensure_buffer_stack(void)
Definition: pycode.cpp:3729
FILE * pycodeYYin
Definition: pycode.cpp:359
static void pycodeYY_load_buffer_state(void)
Definition: pycode.cpp:3562
static void pycodeYY_init_buffer(YY_BUFFER_STATE b, FILE *file)
Definition: pycode.cpp:3623
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_BUF_SIZE
Definition: pycode.cpp:163
void pycodeYYset_debug ( int  debug_flag)

Definition at line 3997 of file pycode.cpp.

3998 {
3999  pycodeYY_flex_debug = bdebug ;
4000 }
int pycodeYY_flex_debug
Definition: pycode.cpp:1147
void pycodeYYset_extra ( YY_EXTRA_TYPE  user_defined)
void pycodeYYset_in ( FILE *  in_str)

Set the input stream. This does not discard the current input buffer.

Parameters
in_strA readable stream.
See also
pycodeYY_switch_to_buffer

Definition at line 3982 of file pycode.cpp.

3983 {
3984  pycodeYYin = in_str ;
3985 }
FILE * pycodeYYin
Definition: pycode.cpp:359
void pycodeYYset_lineno ( int  line_number)

Set the current line number.

Parameters
line_number

Definition at line 3970 of file pycode.cpp.

3971 {
3972 
3973  pycodeYYlineno = line_number;
3974 }
int pycodeYYlineno
Definition: pycode.cpp:365
void pycodeYYset_out ( FILE *  out_str)

Definition at line 3987 of file pycode.cpp.

3988 {
3989  pycodeYYout = out_str ;
3990 }
FILE * pycodeYYout
Definition: pycode.cpp:359
void resetPythonCodeParserState ( )

Definition at line 4123 of file pycode.cpp.

4124 {
4125  g_currentDefinition = 0;
4126  g_currentMemberDef = 0;
4128  g_paramParens = 0;
4129  g_indents.clear();
4130  BEGIN( Body );
4131 }
const bool FALSE
Definition: qglobal.h:370
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
static int g_paramParens
Definition: pycode.cpp:1247
#define BEGIN
Definition: pycode.cpp:144
#define Body
Definition: pycode.cpp:2042
static bool g_doubleStringIsDoc
Definition: pycode.cpp:1256
static QValueStack< uint > g_indents
Tracks indentation levels for scoping in python.
Definition: pycode.cpp:1261
static void setCurrentDoc ( const QCString anchor)
static

Definition at line 1467 of file pycode.cpp.

1468 {
1470  {
1471  if (g_searchCtx)
1472  {
1474  }
1475  else
1476  {
1478  }
1479  }
1480 }
static Definition * g_searchCtx
Definition: pycode.cpp:1234
const bool FALSE
Definition: qglobal.h:370
static SearchIndexIntf * searchIndex
Definition: doxygen.h:133
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
virtual void setCurrentDoc(Definition *ctx, const char *anchor, bool isSourceFile)=0
const bool TRUE
Definition: qglobal.h:371
virtual QCString anchor() const =0
static void startCodeLine ( )
static

start a new line of code, inserting a line number if g_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 1525 of file pycode.cpp.

1526 {
1527  //if (g_currentFontClass) { g_code->endFontClass(); }
1528  if (g_sourceFileDef)
1529  {
1530  //QCString lineNumber,lineAnchor;
1531  //lineNumber.sprintf("%05d",g_yyLineNr);
1532  //lineAnchor.sprintf("l%05d",g_yyLineNr);
1533 
1535  //printf("startCodeLine %d d=%p\n",g_yyLineNr,d);
1536  //g_code->startLineNumber();
1537 
1538  if (!g_includeCodeFragment && d && d->isLinkableInProject())
1539  {
1542  //g_insideBody = FALSE;
1543  g_endComment = FALSE;
1545  g_realScope = d->name().copy();
1546  g_classScope = d->name().copy();
1547  //printf("Real scope: `%s'\n",g_realScope.data());
1548  g_bodyCurlyCount = 0;
1549  QCString lineAnchor;
1550  lineAnchor.sprintf("l%05d",g_yyLineNr);
1551  if (g_currentMemberDef)
1552  {
1556  setCurrentDoc(lineAnchor);
1557  }
1558  else
1559  {
1561  d->getOutputFileBase(),
1562  0,g_yyLineNr);
1563  setCurrentDoc(lineAnchor);
1564  }
1565  }
1566  else
1567  {
1568  //g_code->codify(lineNumber);
1570  }
1571  //g_code->endLineNumber();
1572  }
1574  if (g_currentFontClass)
1575  {
1577  }
1578 }
static bool g_searchingForBody
Definition: pycode.cpp:1245
static QCString g_classScope
Definition: pycode.cpp:1246
virtual QCString getReference() const
QCString getReference() const
Definition: memberdef.cpp:1001
virtual void writeLineNumber(const char *ref, const char *file, const char *anchor, int lineNumber)=0
MemberDef * getSourceMember(int lineNr) const
Definition: filedef.cpp:1226
virtual bool isLinkableInProject() const =0
static int g_bodyCurlyCount
Definition: pycode.cpp:1244
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
const bool FALSE
Definition: qglobal.h:370
virtual void startFontClass(const char *clsName)=0
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
virtual QCString getOutputFileBase() const =0
QCString copy() const
Definition: qcstring.h:250
static QCString g_realScope
Definition: pycode.cpp:1242
const QCString & name() const
Definition: definition.h:114
static void setCurrentDoc(const QCString &anchor)
Definition: pycode.cpp:1467
static MemberDef * g_currentMemberDef
Definition: pycode.cpp:1240
Definition * getSourceDefinition(int lineNr) const
Definition: filedef.cpp:1215
QCString anchor() const
Definition: memberdef.cpp:1031
QCString & sprintf(const char *format,...)
Definition: qcstring.cpp:27
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
virtual void startCodeLine(bool hasLineNumbers)=0
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
static bool g_includeCodeFragment
Definition: pycode.cpp:1241
static const char * g_currentFontClass
Definition: pycode.cpp:1232
QCString getOutputFileBase() const
Definition: memberdef.cpp:941
const bool TRUE
Definition: qglobal.h:371
static bool g_endComment
Definition: pycode.cpp:1264
static void startFontClass ( const char *  s)
static

Definition at line 1645 of file pycode.cpp.

1646 {
1647  // if font class is already set don't stop and start it.
1648  // strcmp does not like null pointers as input.
1650  {
1651  endFontClass();
1654  }
1655 }
static void endFontClass()
Definition: pycode.cpp:1657
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
virtual void startFontClass(const char *clsName)=0
int strcmp(const String &s1, const String &s2)
Definition: relates.cpp:14
static const char * g_currentFontClass
Definition: pycode.cpp:1232
static QCString * s
Definition: config.cpp:1042
static ClassDef* stripClassName ( const char *  s,
Definition d = g_currentDefinition 
)
static

Definition at line 1491 of file pycode.cpp.

1492 {
1493  int pos=0;
1494  QCString type = s;
1496  QCString templSpec;
1497  while (extractClassNameFromType(type,pos,className,templSpec)!=-1)
1498  {
1499  QCString clName=className+templSpec;
1500 
1501  ClassDef *cd=0;
1502  if (!g_classScope.isEmpty())
1503  {
1504  cd=getResolvedClass(d,g_sourceFileDef,g_classScope+"::"+clName);
1505  }
1506  if (cd==0)
1507  {
1508  cd=getResolvedClass(d,g_sourceFileDef,clName);
1509  }
1510  if (cd)
1511  {
1512  return cd;
1513  }
1514  }
1515 
1516  return 0;
1517 }
static QCString g_classScope
Definition: pycode.cpp:1246
bool isEmpty() const
Definition: qcstring.h:189
static QCString className
Definition: declinfo.cpp:669
int extractClassNameFromType(const QCString &type, int &pos, QCString &name, QCString &templSpec, SrcLangExt lang)
Definition: util.cpp:5963
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
ClassDef * getResolvedClass(Definition *scope, FileDef *fileScope, const char *n, MemberDef **pTypeDef, QCString *pTemplSpec, bool mayBeUnlinkable, bool mayBeHidden, QCString *pResolvedType)
Definition: util.cpp:1563
static QCString * s
Definition: config.cpp:1042
while ( )

Definition at line 2283 of file pycode.cpp.

2284  {
2285  yy_cp = (yy_c_buf_p);
2286 
2287  /* Support of pycodeYYtext. */
2288  *yy_cp = (yy_hold_char);
2289 
2290  /* yy_bp points to the position in yy_ch_buf of the start of
2291  * the current run.
2292  */
2293  yy_bp = yy_cp;
2294 
2295  yy_current_state = (yy_start);
2296 
2297  (yy_state_ptr) = (yy_state_buf);
2298  *(yy_state_ptr)++ = yy_current_state;
2299 
2300 yy_match:
2301  do
2302  {
2303  register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
2304  while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2305  {
2306  yy_current_state = (int) yy_def[yy_current_state];
2307  if ( yy_current_state >= 540 )
2308  yy_c = yy_meta[(unsigned int) yy_c];
2309  }
2310  yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
2311  *(yy_state_ptr)++ = yy_current_state;
2312  ++yy_cp;
2313  }
2314  while ( yy_current_state != 539 );
2315 
2316 yy_find_action:
2317  yy_current_state = *--(yy_state_ptr);
2318  (yy_lp) = yy_accept[yy_current_state];
2319 find_rule: /* we branch to this label when backing up */
2320  for ( ; ; ) /* until we find what rule we matched */
2321  {
2322  if ( (yy_lp) && (yy_lp) < yy_accept[yy_current_state + 1] )
2323  {
2324  yy_act = yy_acclist[(yy_lp)];
2325  if ( yy_act & YY_TRAILING_HEAD_MASK ||
2327  {
2329  {
2332  break;
2333  }
2334  }
2335  else if ( yy_act & YY_TRAILING_MASK )
2336  {
2337  (yy_looking_for_trail_begin) = yy_act & ~YY_TRAILING_MASK;
2339  (yy_full_match) = yy_cp;
2341  (yy_full_lp) = (yy_lp);
2342  }
2343  else
2344  {
2345  (yy_full_match) = yy_cp;
2347  (yy_full_lp) = (yy_lp);
2348  break;
2349  }
2350  ++(yy_lp);
2351  goto find_rule;
2352  }
2353  --yy_cp;
2354  yy_current_state = *--(yy_state_ptr);
2355  (yy_lp) = yy_accept[yy_current_state];
2356  }
2357 
2359 
2360 do_action: /* This label is used only to access EOF actions. */
2361 
2362  switch ( yy_act )
2363  { /* beginning of action switch */
2364 
2365 case 1:
2367 #line 992 "pycode.l"
2368 {
2369  startFontClass("keyword");
2371  endFontClass();
2372  BEGIN( FunctionDec );
2373  }
2374  YY_BREAK
2375 case 2:
2377 #line 999 "pycode.l"
2378 {
2379  startFontClass("keyword");
2381  endFontClass();
2382  BEGIN( ClassDec );
2383  }
2384  YY_BREAK
2385 case 3:
2387 #line 1005 "pycode.l"
2388 {
2389  startFontClass("keywordtype");
2391  endFontClass();
2392  }
2393  YY_BREAK
2394 case 4:
2395 *yy_cp = (yy_hold_char); /* undo effects of setting up pycodeYYtext */
2396 (yy_c_buf_p) = yy_cp -= 1;
2397 YY_DO_BEFORE_ACTION; /* set up pycodeYYtext again */
2399 #line 1010 "pycode.l"
2400 {
2401  codify("self.");
2403  }
2404  YY_BREAK
2405 case 5:
2407 #line 1014 "pycode.l"
2408 {
2409  codify("self.");
2411  }
2412  YY_BREAK
2413 case 6:
2414 *yy_cp = (yy_hold_char); /* undo effects of setting up pycodeYYtext */
2415 (yy_c_buf_p) = yy_cp -= 1;
2416 YY_DO_BEFORE_ACTION; /* set up pycodeYYtext again */
2418 #line 1018 "pycode.l"
2419 {
2420  codify("cls.");
2422  }
2423  YY_BREAK
2424 case 7:
2426 #line 1022 "pycode.l"
2427 {
2428  codify("cls.");
2430  }
2431  YY_BREAK
2432 
2433 case 8:
2435 #line 1028 "pycode.l"
2436 {
2437 
2439  // codify(pycodeYYtext);
2443  }
2444  YY_BREAK
2445 
2446 case 9:
2448 #line 1038 "pycode.l"
2449 {
2451  }
2452  YY_BREAK
2453 case 10:
2455 #line 1042 "pycode.l"
2456 {
2457  // The parser
2458  // is assuming
2459  // that ALL identifiers
2460  // in this state
2461  // are base classes;
2462  // it doesn't check to see
2463  // that the first parenthesis
2464  // has been seen.
2465 
2466  // This is bad - it should
2467  // probably be more strict
2468  // about what to accept.
2469 
2472  // codify(pycodeYYtext);
2473  }
2474  YY_BREAK
2475 case 11:
2477 #line 1061 "pycode.l"
2478 {
2480 
2481  // Assume this will
2482  // be a one-line suite;
2483  // found counter-example
2484  // in SuiteStart.
2485 
2486  // Push a class scope
2487 
2488  ClassDef *classDefToAdd = new ClassDef("<code>",1,1,g_curClassName,ClassDef::Class,0,0,FALSE);
2489  g_codeClassSDict.append(g_curClassName,classDefToAdd);
2490  char *s=g_curClassBases.first();
2491  while (s)
2492  {
2493  ClassDef *baseDefToAdd;
2494  baseDefToAdd=g_codeClassSDict[s];
2495 
2496  // Try to find class in global
2497  // scope
2498  if (baseDefToAdd==0)
2499  {
2501  }
2502 
2503  if (baseDefToAdd && baseDefToAdd!=classDefToAdd)
2504  {
2505  classDefToAdd->insertBaseClass(baseDefToAdd,s,Public,Normal);
2506  }
2507 
2508  s=g_curClassBases.next();
2509  }
2510 
2511  // Reset class-parsing variables.
2514 
2515  g_noSuiteFound = TRUE;
2516  BEGIN( SuiteStart );
2517  }
2518  YY_BREAK
2519 
2520 
2521 case 12:
2523 #line 1105 "pycode.l"
2524 {
2526  }
2527  YY_BREAK
2528 case 13:
2530 #line 1109 "pycode.l"
2531 {
2533  BEGIN( FunctionParams );
2534  }
2535  YY_BREAK
2536 
2537 
2538 case 14:
2540 #line 1116 "pycode.l"
2541 {
2542  // Parses delimiters
2544  }
2545  YY_BREAK
2546 case 15:
2548 #line 1121 "pycode.l"
2549 {
2551  }
2552  YY_BREAK
2553 case 16:
2555 #line 1125 "pycode.l"
2556 {
2558  }
2559  YY_BREAK
2560 case 17:
2562 #line 1129 "pycode.l"
2563 {
2565 
2566  // Assume this will
2567  // be a one-line suite;
2568  // found counter-example
2569  // in SuiteStart.
2570  g_noSuiteFound = TRUE;
2571  BEGIN( SuiteStart );
2572  }
2573  YY_BREAK
2574 
2575 
2576 case 18:
2578 #line 1143 "pycode.l"
2579 {
2580  // Position-sensitive rules!
2581  // Must come AFTER keyword-triggered rules
2582  // Must come BEFORE identifier NONEMPTY-like rules
2583  // to syntax highlight.
2584 
2585  startFontClass("keyword");
2587  endFontClass();
2588  }
2589  YY_BREAK
2590 case 19:
2592 #line 1154 "pycode.l"
2593 {
2594  startFontClass("keywordflow");
2596  endFontClass();
2597  }
2598  YY_BREAK
2599 case 20:
2600 *yy_cp = (yy_hold_char); /* undo effects of setting up pycodeYYtext */
2601 (yy_c_buf_p) = yy_cp -= 1;
2602 YY_DO_BEFORE_ACTION; /* set up pycodeYYtext again */
2604 #line 1159 "pycode.l"
2605 {
2607  }
2608  YY_BREAK
2609 case 21:
2611 #line 1162 "pycode.l"
2612 {
2614  }
2615  YY_BREAK
2616 case 22:
2618 #line 1165 "pycode.l"
2619 { codify(pycodeYYtext); }
2620  YY_BREAK
2621 
2622 
2623 case 23:
2625 #line 1173 "pycode.l"
2626 {
2628  }
2629  YY_BREAK
2630 case 24:
2632 #line 1176 "pycode.l"
2633 {
2634  startFontClass("keyword");
2636  endFontClass();
2637  BEGIN(Body);
2638  }
2639  YY_BREAK
2640 case 25:
2642 #line 1182 "pycode.l"
2643 {
2644  startFontClass("keyword");
2646  endFontClass();
2647 
2648  // No indentation necessary
2650  }
2651  YY_BREAK
2652 case 26:
2654 #line 1191 "pycode.l"
2655 {
2656  startFontClass("keywordflow");
2658  endFontClass();
2659 
2660  // No indentation necessary
2662  }
2663  YY_BREAK
2664 case 27:
2666 #line 1199 "pycode.l"
2667 {
2669  }
2670  YY_BREAK
2671 case 28:
2673 #line 1204 "pycode.l"
2674 {
2675  if (YY_START==SingleQuoteString ||
2678  )
2679  {
2680  REJECT;
2681  }
2683  BEGIN(DocBlock);
2685  }
2686  YY_BREAK
2687 case 29:
2688 /* rule 29 can match eol */
2690 #line 1217 "pycode.l"
2691 {
2693  if ( g_noSuiteFound )
2694  {
2695  // printf("New suite to capture! [%d]\n", g_yyLineNr);
2697  }
2698  }
2699  YY_BREAK
2700 
2701 
2702 case 30:
2703 /* rule 30 can match eol */
2705 #line 1228 "pycode.l"
2706 {
2707  // Blankline - ignore, keep looking for indentation.
2709  }
2710  YY_BREAK
2711 case 31:
2713 #line 1233 "pycode.l"
2714 {
2715  // This state lasts momentarily,
2716  // to check the indentation
2717  // level that is about to be
2718  // used.
2720  g_indents.push(pycodeYYleng);
2721  // printf("Captured indent of %d [line %d]\n", pycodeYYleng, g_yyLineNr);
2722  BEGIN( Suite );
2723  }
2724  YY_BREAK
2725 
2726 
2727 case 32:
2729 #line 1247 "pycode.l"
2730 {
2731  // This implements poor
2732  // indendation-tracking;
2733  // should be improved.
2734  // (translate tabs to space, etc)
2737  }
2738  YY_BREAK
2739 case 33:
2740 /* rule 33 can match eol */
2742 #line 1256 "pycode.l"
2743 {
2744  // If this ever succeeds,
2745  // it means that this is
2746  // a blank line, and
2747  // can be ignored.
2749  }
2750  YY_BREAK
2751 case 34:
2753 #line 1264 "pycode.l"
2754 {
2755  // Default rule; matches
2756  // the empty string, assuming
2757  // real text starts here.
2758  // Just go straight to Body.
2760  }
2761  YY_BREAK
2762 
2763 case 35:
2764 /* rule 35 can match eol */
2766 #line 1274 "pycode.l"
2767 {
2769  BEGIN( SuiteMaintain );
2770  }
2771  YY_BREAK
2772 case 36:
2774 #line 1278 "pycode.l"
2775 {
2777  }
2778  YY_BREAK
2779 case 37:
2780 /* rule 37 can match eol */
2782 #line 1281 "pycode.l"
2783 {
2785  }
2786  YY_BREAK
2787 // Single quoted string like 'That\'s a """nice""" string!'
2788 case 38:
2789 /* rule 38 can match eol */
2791 #line 1286 "pycode.l"
2792 { // line continuation
2794  }
2795  YY_BREAK
2796 case 39:
2798 #line 1289 "pycode.l"
2799 { // espaced char
2801  }
2802  YY_BREAK
2803 case 40:
2805 #line 1292 "pycode.l"
2806 { // tripple double quotes
2808  }
2809  YY_BREAK
2810 case 41:
2812 #line 1295 "pycode.l"
2813 { // end of the string
2815  endFontClass();
2817  }
2818  YY_BREAK
2819 case 42:
2821 #line 1300 "pycode.l"
2822 { // normal chars
2824  }
2825  YY_BREAK
2826 case 43:
2828 #line 1303 "pycode.l"
2829 { // normal char
2831  }
2832  YY_BREAK
2833 
2834 // Double quoted string like "That's \"a '''nice'''\" string!"
2835 case 44:
2836 /* rule 44 can match eol */
2838 #line 1309 "pycode.l"
2839 { // line continuation
2841  }
2842  YY_BREAK
2843 case 45:
2845 #line 1312 "pycode.l"
2846 { // espaced char
2848  }
2849  YY_BREAK
2850 case 46:
2852 #line 1315 "pycode.l"
2853 { // tripple single quotes
2855  }
2856  YY_BREAK
2857 case 47:
2859 #line 1318 "pycode.l"
2860 { // end of the string
2862  endFontClass();
2864  }
2865  YY_BREAK
2866 case 48:
2868 #line 1323 "pycode.l"
2869 { // normal chars
2871  }
2872  YY_BREAK
2873 case 49:
2875 #line 1326 "pycode.l"
2876 { // normal char
2878  }
2879  YY_BREAK
2880 
2881 
2882 case 50:
2883 #line 1333 "pycode.l"
2884 case 51:
2886 #line 1333 "pycode.l"
2887 {
2889  if (g_doubleQuote==(pycodeYYtext[0]=='"'))
2890  {
2891  endFontClass();
2893  }
2894  }
2895  YY_BREAK
2896 case 52:
2897 /* rule 52 can match eol */
2899 #line 1341 "pycode.l"
2900 {
2902  }
2903  YY_BREAK
2904 case 53:
2905 /* rule 53 can match eol */
2907 #line 1344 "pycode.l"
2908 {
2910  }
2911  YY_BREAK
2912 case 54:
2914 #line 1347 "pycode.l"
2915 {
2917  }
2918  YY_BREAK
2919 
2920 /*
2921 <*>({NONEMPTY}|{EXPCHAR}|{BB}) { // This should go one character at a time.
2922  codify(pycodeYYtext);
2923  // printf("[pycode] '%s' [ state %d ] [line %d] no match\n",
2924  // pycodeYYtext, YY_START, g_yyLineNr);
2925 
2926  //endFontClass();
2927  BEGIN(Body);
2928  }
2929  */
2930 case 55:
2931 #line 1364 "pycode.l"
2932 case 56:
2934 #line 1364 "pycode.l"
2935 {
2936  startFontClass("stringliteral");
2941  }
2942  YY_BREAK
2943 case 57:
2945 #line 1371 "pycode.l"
2946 { // single quoted string
2947  startFontClass("stringliteral");
2951  }
2952  YY_BREAK
2953 case 58:
2955 #line 1377 "pycode.l"
2956 { // double quoted string
2957  startFontClass("stringliteral");
2961  }
2962  YY_BREAK
2963 case 59:
2965 #line 1383 "pycode.l"
2966 { // contents of current comment line
2968  }
2969  YY_BREAK
2970 case 60:
2971 /* rule 60 can match eol */
2973 #line 1386 "pycode.l"
2974 { // comment block (next line is also comment line)
2976  }
2977  YY_BREAK
2978 case 61:
2979 /* rule 61 can match eol */
2981 #line 1389 "pycode.l"
2982 { // comment block ends at the end of this line
2983  // remove special comment (default config)
2984  if (Config_getBool("STRIP_CODE_COMMENTS"))
2985  {
2986  g_yyLineNr+=((QCString)g_docBlock).contains('\n');
2988  }
2989  else // do not remove comment
2990  {
2991  startFontClass("comment");
2993  endFontClass();
2994  }
2995  unput(*pycodeYYtext);
2996  yy_pop_state();
2997  }
2998  YY_BREAK
2999 case 62:
3001 #line 1405 "pycode.l"
3002 {
3003  if (YY_START==SingleQuoteString ||
3006  )
3007  {
3008  REJECT;
3009  }
3011  BEGIN(DocBlock);
3013  }
3014  YY_BREAK
3015 case 63:
3017 #line 1417 "pycode.l"
3018 { // normal comment
3019  if (YY_START==SingleQuoteString ||
3022  )
3023  {
3024  REJECT;
3025  }
3026  startFontClass("comment");
3028  endFontClass();
3029  }
3030  YY_BREAK
3031 case 64:
3032 /* rule 64 can match eol */
3034 #line 1429 "pycode.l"
3035 {
3036  if (g_endComment)
3037  {
3039  }
3040  else
3041  {
3043  }
3044  //printf("[pycode] %d NEWLINE [line %d] no match\n",
3045  // YY_START, g_yyLineNr);
3046 
3047  //endFontClass();
3048  BEGIN(Body);
3049  }
3050  YY_BREAK
3051 case 65:
3053 #line 1445 "pycode.l"
3054 {
3056  BEGIN(Body);
3057  }
3058  YY_BREAK
3059 case 66:
3061 #line 1449 "pycode.l"
3062 {
3064  // printf("[pycode] '%s' [ state %d ] [line %d] no match\n",
3065  // pycodeYYtext, YY_START, g_yyLineNr);
3066 
3067  //endFontClass();
3068  BEGIN(Body);
3069  }
3070  YY_BREAK
3071 case YY_STATE_EOF(INITIAL):
3072 case YY_STATE_EOF(Body):
3073 case YY_STATE_EOF(FunctionDec):
3074 case YY_STATE_EOF(FunctionParams):
3075 case YY_STATE_EOF(ClassDec):
3076 case YY_STATE_EOF(ClassInheritance):
3077 case YY_STATE_EOF(Suite):
3078 case YY_STATE_EOF(SuiteCaptureIndent):
3079 case YY_STATE_EOF(SuiteStart):
3080 case YY_STATE_EOF(SuiteMaintain):
3081 case YY_STATE_EOF(SuiteContinuing):
3082 case YY_STATE_EOF(LongString):
3083 case YY_STATE_EOF(SingleQuoteString):
3084 case YY_STATE_EOF(DoubleQuoteString):
3085 case YY_STATE_EOF(TripleString):
3086 case YY_STATE_EOF(DocBlock):
3087 #line 1458 "pycode.l"
3088 {
3089  if (YY_START == DocBlock) {
3090  if (!Config_getBool("STRIP_CODE_COMMENTS"))
3091  {
3092  startFontClass("comment");
3094  endFontClass();
3095  }
3096  }
3097  yyterminate();
3098  }
3099  YY_BREAK
3100 case 67:
3102 #line 1469 "pycode.l"
3103 ECHO;
3104  YY_BREAK
3105 #line 3106 "/nova/app/home/novasoft/doxygen/doxygen-1.8.11/build/generated_src/pycode.cpp"
3106 
3107  case YY_END_OF_BUFFER:
3108  {
3109  /* Amount of text matched not including the EOB char. */
3110  int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
3111 
3112  /* Undo the effects of YY_DO_BEFORE_ACTION. */
3113  *yy_cp = (yy_hold_char);
3115 
3116  if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
3117  {
3118  /* We're scanning a new file or input source. It's
3119  * possible that this happened because the user
3120  * just pointed pycodeYYin at a new source and called
3121  * pycodeYYlex(). If so, then we have to assure
3122  * consistency between YY_CURRENT_BUFFER and our
3123  * globals. Here is the right place to do so, because
3124  * this is the first action (other than possibly a
3125  * back-up) that will match for the new input source.
3126  */
3127  (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
3128  YY_CURRENT_BUFFER_LVALUE->yy_input_file = pycodeYYin;
3129  YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
3130  }
3131 
3132  /* Note that here we test for yy_c_buf_p "<=" to the position
3133  * of the first EOB in the buffer, since yy_c_buf_p will
3134  * already have been incremented past the NUL character
3135  * (since all states make transitions on EOB to the
3136  * end-of-buffer state). Contrast this with the test
3137  * in input().
3138  */
3139  if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] )
3140  { /* This was really a NUL. */
3141  yy_state_type yy_next_state;
3142 
3143  (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text;
3144 
3145  yy_current_state = yy_get_previous_state( );
3146 
3147  /* Okay, we're now positioned to make the NUL
3148  * transition. We couldn't have
3149  * yy_get_previous_state() go ahead and do it
3150  * for us because it doesn't know how to deal
3151  * with the possibility of jamming (and we don't
3152  * want to build jamming into it because then it
3153  * will run more slowly).
3154  */
3155 
3156  yy_next_state = yy_try_NUL_trans( yy_current_state );
3157 
3159 
3160  if ( yy_next_state )
3161  {
3162  /* Consume the NUL. */
3163  yy_cp = ++(yy_c_buf_p);
3164  yy_current_state = yy_next_state;
3165  goto yy_match;
3166  }
3167 
3168  else
3169  {
3170  yy_cp = (yy_c_buf_p);
3171  goto yy_find_action;
3172  }
3173  }
3174 
3175  else switch ( yy_get_next_buffer( ) )
3176  {
3177  case EOB_ACT_END_OF_FILE:
3178  {
3180 
3181  if ( pycodeYYwrap( ) )
3182  {
3183  /* Note: because we've taken care in
3184  * yy_get_next_buffer() to have set up
3185  * pycodeYYtext, we can now set up
3186  * yy_c_buf_p so that if some total
3187  * hoser (like flex itself) wants to
3188  * call the scanner after we return the
3189  * YY_NULL, it'll still work - another
3190  * YY_NULL will get returned.
3191  */
3193 
3195  goto do_action;
3196  }
3197 
3198  else
3199  {
3200  if ( ! (yy_did_buffer_switch_on_eof) )
3201  YY_NEW_FILE;
3202  }
3203  break;
3204  }
3205 
3206  case EOB_ACT_CONTINUE_SCAN:
3207  (yy_c_buf_p) =
3208  (yytext_ptr) + yy_amount_of_matched_text;
3209 
3210  yy_current_state = yy_get_previous_state( );
3211 
3212  yy_cp = (yy_c_buf_p);
3214  goto yy_match;
3215 
3216  case EOB_ACT_LAST_MATCH:
3217  (yy_c_buf_p) =
3218  &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)];
3219 
3220  yy_current_state = yy_get_previous_state( );
3221 
3222  yy_cp = (yy_c_buf_p);
3224  goto yy_find_action;
3225  }
3226  break;
3227  }
3228 
3229  default:
3231  "fatal flex scanner internal error--no action found" );
3232  } /* end of action switch */
3233  } /* end of scanning one token */
static void endFontClass()
Definition: pycode.cpp:1657
static int yy_n_chars
Definition: pycode.cpp:293
bool resize(uint newlen)
Definition: qcstring.h:225
static yyconst flex_int16_t yy_nxt[1769]
Definition: pycode.cpp:750
static bool g_noSuiteFound
Definition: pycode.cpp:1258
static char * yy_full_match
Definition: pycode.cpp:1150
#define YY_BREAK
Definition: pycode.cpp:2232
#define SuiteMaintain
Definition: pycode.cpp:2050
static yy_state_type * yy_state_ptr
Definition: pycode.cpp:1149
#define TripleString
Definition: pycode.cpp:2055
static bool findMemberLink(CodeOutputInterface &ol, Definition *sym, const char *symName)
Definition: pycode.cpp:1947
#define EOB_ACT_LAST_MATCH
Definition: pycode.cpp:181
static yyconst flex_int32_t yy_meta[44]
Definition: pycode.cpp:607
static int yy_get_next_buffer(void)
Definition: pycode.cpp:3243
#define yytext_ptr
Definition: pycode.cpp:368
register int yy_act
Definition: pycode.cpp:2244
Definition: types.h:26
static yy_state_type yy_get_previous_state(void)
Definition: pycode.cpp:3348
#define SuiteStart
Definition: pycode.cpp:2049
static int yy_did_buffer_switch_on_eof
Definition: pycode.cpp:304
#define YY_BUFFER_NORMAL
Definition: pycode.cpp:255
type * first()
Definition: qinternallist.h:87
#define unput(c)
Definition: pycode.cpp:199
static CodeOutputInterface * g_code
Definition: pycode.cpp:1229
static void generateClassOrGlobalLink(CodeOutputInterface &ol, char *clName, bool typeOnly=FALSE)
Definition: pycode.cpp:1777
#define Suite
Definition: pycode.cpp:2047
static ClassSDict g_codeClassSDict(17)
static char * yy_c_buf_p
Definition: pycode.cpp:297
static int yy_lp
Definition: pycode.cpp:1151
const bool FALSE
Definition: qglobal.h:370
#define DoubleQuoteString
Definition: pycode.cpp:2054
static Definition * g_currentDefinition
Definition: pycode.cpp:1239
static int * yy_full_state
Definition: pycode.cpp:1154
#define ECHO
Definition: pycode.cpp:2153
static int g_stringContext
Definition: pycode.cpp:1259
void append(const char *key, const T *d)
Definition: sortdict.h:135
static yyconst flex_int32_t yy_ec[256]
Definition: pycode.cpp:575
int yy_state_type
Definition: code.cpp:361
Definition: types.h:29
char * pycodeYYtext
Definition: pycode.cpp:1171
#define FunctionParams
Definition: pycode.cpp:2044
register char * yy_bp
Definition: pycode.cpp:2243
#define pycodeYYwrap(n)
Definition: pycode.cpp:354
#define YY_TRAILING_HEAD_MASK
Definition: pycode.cpp:1156
#define SingleQuoteString
Definition: pycode.cpp:2053
static char yy_hold_char
Definition: pycode.cpp:292
static int yy_looking_for_trail_begin
Definition: pycode.cpp:1152
static void yy_pop_state(void)
Definition: pycode.cpp:3882
static yyconst flex_int16_t yy_chk[1769]
Definition: pycode.cpp:948
#define INITIAL
Definition: pycode.cpp:2041
static QCString g_curClassName
Definition: pycode.cpp:1225
static void startFontClass(const char *s)
Definition: pycode.cpp:1645
#define DocBlock
Definition: pycode.cpp:2056
#define ClassInheritance
Definition: pycode.cpp:2046
#define FunctionDec
Definition: pycode.cpp:2043
FILE * pycodeYYin
Definition: pycode.cpp:359
void inSort(const type *d)
Definition: qinternallist.h:59
#define YY_END_OF_BUFFER
Definition: pycode.cpp:386
static yyconst flex_int16_t yy_def[574]
Definition: pycode.cpp:683
#define Config_getBool(val)
Definition: config.cpp:664
unsigned char YY_CHAR
Definition: code.cpp:357
type * next()
Definition: qinternallist.h:89
#define EOB_ACT_CONTINUE_SCAN
Definition: pycode.cpp:179
static QCString g_docBlock
contents of all lines of a documentation block
Definition: pycode.cpp:1263
static yyconst flex_int16_t yy_base[574]
Definition: pycode.cpp:616
#define EOB_ACT_END_OF_FILE
Definition: pycode.cpp:180
static void codify(const char *text)
Definition: pycode.cpp:1580
#define ClassDec
Definition: pycode.cpp:2045
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
void insertBaseClass(ClassDef *, const char *name, Protection p, Specifier s, const char *t=0)
Definition: classdef.cpp:358
#define YY_RULE_SETUP
Definition: pycode.cpp:2235
static yy_state_type yy_try_NUL_trans(yy_state_type current_state)
Definition: pycode.cpp:3379
#define YY_DO_BEFORE_ACTION
Definition: pycode.cpp:378
#define YY_NEW_FILE
Definition: pycode.cpp:157
#define BEGIN
Definition: pycode.cpp:144
static QStrList g_curClassBases
Definition: pycode.cpp:1226
#define SuiteCaptureIndent
Definition: pycode.cpp:2048
static FileDef * g_sourceFileDef
Definition: pycode.cpp:1238
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_START
Definition: pycode.cpp:150
void line(double t, double *p, double &x, double &y, double &z)
register char * yy_cp
Definition: pycode.cpp:2243
#define Body
Definition: pycode.cpp:2042
static void generateFunctionLink(CodeOutputInterface &ol, char *funcName)
Definition: pycode.cpp:1911
#define YY_RESTORE_YY_MORE_OFFSET
Definition: pycode.cpp:1170
static yyconst flex_int16_t yy_acclist[1033]
Definition: pycode.cpp:394
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
static void adjustScopesAndSuites(unsigned indentLength)
Definition: pycode.cpp:4137
#define LongString
Definition: pycode.cpp:2052
#define YY_MORE_ADJ
Definition: pycode.cpp:1169
static void codifyLines(char *text)
Definition: pycode.cpp:1666
#define SuiteContinuing
Definition: pycode.cpp:2051
static bool g_doubleQuote
Definition: pycode.cpp:1257
ClassDef * getResolvedClass(Definition *scope, FileDef *fileScope, const char *n, MemberDef **pTypeDef, QCString *pTemplSpec, bool mayBeUnlinkable, bool mayBeHidden, QCString *pResolvedType)
Definition: util.cpp:1563
#define YY_STATE_EOF(state)
Definition: pycode.cpp:154
static void yy_push_state(int new_state)
Definition: pycode.cpp:3858
#define yyterminate()
Definition: pycode.cpp:2197
static QCString * s
Definition: config.cpp:1042
static QValueStack< uint > g_indents
Tracks indentation levels for scoping in python.
Definition: pycode.cpp:1261
const bool TRUE
Definition: qglobal.h:371
static bool g_endComment
Definition: pycode.cpp:1264
static int yy_full_lp
Definition: pycode.cpp:1153
static int yy_start
Definition: pycode.cpp:299
#define YY_BUFFER_NEW
Definition: pycode.cpp:254
#define YY_TRAILING_MASK
Definition: pycode.cpp:1155
int pycodeYYleng
Definition: pycode.cpp:294
#define YY_SC_TO_UI(c)
Definition: pycode.cpp:138
#define REJECT
Definition: pycode.cpp:1157
static yy_state_type * yy_state_buf
Definition: pycode.cpp:1149
static yyconst flex_int16_t yy_accept[541]
Definition: pycode.cpp:512
static void writeMultiLineCodeLink ( CodeOutputInterface ol,
Definition d,
const char *  text 
)
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 1607 of file pycode.cpp.

1610 {
1611  static bool sourceTooltips = Config_getBool("SOURCE_TOOLTIPS");
1613  QCString ref = d->getReference();
1615  QCString anchor = d->anchor();
1616  QCString tooltip;
1617  if (!sourceTooltips) // fall back to simple "title" tooltips
1618  {
1619  tooltip = d->briefDescriptionAsTooltip();
1620  }
1621  bool done=FALSE;
1622  char *p=(char *)text;
1623  while (!done)
1624  {
1625  char *sp=p;
1626  char c;
1627  while ((c=*p++) && c!='\n') { }
1628  if (c=='\n')
1629  {
1630  g_yyLineNr++;
1631  *(p-1)='\0';
1632  //printf("writeCodeLink(%s,%s,%s,%s)\n",ref,file,anchor,sp);
1633  ol.writeCodeLink(ref,file,anchor,sp,tooltip);
1634  nextCodeLine();
1635  }
1636  else
1637  {
1638  //printf("writeCodeLink(%s,%s,%s,%s)\n",ref,file,anchor,sp);
1639  ol.writeCodeLink(ref,file,anchor,sp,tooltip);
1640  done=TRUE;
1641  }
1642  }
1643 }
virtual QCString getReference() const
void addTooltip(Definition *d)
Definition: tooltip.cpp:71
const bool FALSE
Definition: qglobal.h:370
virtual QCString getOutputFileBase() const =0
virtual void writeCodeLink(const char *ref, const char *file, const char *anchor, const char *name, const char *tooltip)=0
p
Definition: test.py:223
#define Config_getBool(val)
Definition: config.cpp:664
static int g_yyLineNr
current line number
Definition: pycode.cpp:1237
static void nextCodeLine()
Definition: pycode.cpp:1591
static TooltipManager * instance()
Definition: tooltip.cpp:45
QCString briefDescriptionAsTooltip() const
const bool TRUE
Definition: qglobal.h:371
virtual QCString anchor() const =0
static void yy_fatal_error ( yyconst char  msg[])
static
static void yy_fatal_error ( yyconst char *  msg)
static

Definition at line 3899 of file pycode.cpp.

3900 {
3901  (void) fprintf( stderr, "%s\n", msg );
3902  exit( YY_EXIT_FAILURE );
3903 }
void msg(const char *fmt,...)
Definition: message.cpp:107
#define YY_EXIT_FAILURE
Definition: pycode.cpp:3896
static int yy_get_next_buffer ( void  )
static

Definition at line 3243 of file pycode.cpp.

3244 {
3245  register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
3246  register char *source = (yytext_ptr);
3247  register int number_to_move, i;
3248  int ret_val;
3249 
3250  if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] )
3252  "fatal flex scanner internal error--end of buffer missed" );
3253 
3254  if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
3255  { /* Don't try to fill the buffer, so this is an EOF. */
3256  if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
3257  {
3258  /* We matched a single character, the EOB, so
3259  * treat this as a final EOF.
3260  */
3261  return EOB_ACT_END_OF_FILE;
3262  }
3263 
3264  else
3265  {
3266  /* We matched some text prior to the EOB, first
3267  * process it.
3268  */
3269  return EOB_ACT_LAST_MATCH;
3270  }
3271  }
3272 
3273  /* Try to read more data. */
3274 
3275  /* First move last chars to start of buffer. */
3276  number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;
3277 
3278  for ( i = 0; i < number_to_move; ++i )
3279  *(dest++) = *(source++);
3280 
3281  if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
3282  /* don't do the read, it's not guaranteed to return an EOF,
3283  * just force an EOF
3284  */
3285  YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
3286 
3287  else
3288  {
3289  int num_to_read =
3290  YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
3291 
3292  while ( num_to_read <= 0 )
3293  { /* Not enough room in the buffer - grow it. */
3294 
3296 "input buffer overflow, can't enlarge buffer because scanner uses REJECT" );
3297 
3298  }
3299 
3300  if ( num_to_read > YY_READ_BUF_SIZE )
3301  num_to_read = YY_READ_BUF_SIZE;
3302 
3303  /* Read in more data. */
3304  YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
3305  (yy_n_chars), (size_t) num_to_read );
3306 
3307  YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
3308  }
3309 
3310  if ( (yy_n_chars) == 0 )
3311  {
3312  if ( number_to_move == YY_MORE_ADJ )
3313  {
3314  ret_val = EOB_ACT_END_OF_FILE;
3316  }
3317 
3318  else
3319  {
3320  ret_val = EOB_ACT_LAST_MATCH;
3321  YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
3323  }
3324  }
3325 
3326  else
3327  ret_val = EOB_ACT_CONTINUE_SCAN;
3328 
3329  if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
3330  /* Extend the array by 50%, plus the number we really need. */
3331  yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1);
3332  YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) pycodeYYrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size );
3333  if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
3334  YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
3335  }
3336 
3337  (yy_n_chars) += number_to_move;
3340 
3341  (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
3342 
3343  return ret_val;
3344 }
static int yy_n_chars
Definition: pycode.cpp:293
#define YY_READ_BUF_SIZE
Definition: pycode.cpp:2145
#define EOB_ACT_LAST_MATCH
Definition: pycode.cpp:181
#define yytext_ptr
Definition: pycode.cpp:368
static char * yy_c_buf_p
Definition: pycode.cpp:297
void pycodeYYrestart(FILE *input_file)
Definition: pycode.cpp:3514
#define YY_END_OF_BUFFER_CHAR
Definition: pycode.cpp:159
#define YY_BUFFER_EOF_PENDING
Definition: pycode.cpp:266
FILE * pycodeYYin
Definition: pycode.cpp:359
void * pycodeYYrealloc(void *, yy_size_t)
Definition: pycode.cpp:4097
#define EOB_ACT_CONTINUE_SCAN
Definition: pycode.cpp:179
#define EOB_ACT_END_OF_FILE
Definition: pycode.cpp:180
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
#define YY_MORE_ADJ
Definition: pycode.cpp:1169
size_t yy_size_t
Definition: code.cpp:203
#define YY_INPUT(buf, result, max_size)
Definition: pycode.cpp:2011
static yy_state_type yy_get_previous_state ( void  )
static

Definition at line 3348 of file pycode.cpp.

3349 {
3350  register yy_state_type yy_current_state;
3351  register char *yy_cp;
3352 
3353  yy_current_state = (yy_start);
3354 
3355  (yy_state_ptr) = (yy_state_buf);
3356  *(yy_state_ptr)++ = yy_current_state;
3357 
3358  for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
3359  {
3360  register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
3361  while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3362  {
3363  yy_current_state = (int) yy_def[yy_current_state];
3364  if ( yy_current_state >= 540 )
3365  yy_c = yy_meta[(unsigned int) yy_c];
3366  }
3367  yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3368  *(yy_state_ptr)++ = yy_current_state;
3369  }
3370 
3371  return yy_current_state;
3372 }
static yyconst flex_int16_t yy_nxt[1769]
Definition: pycode.cpp:750
static yy_state_type * yy_state_ptr
Definition: pycode.cpp:1149
static yyconst flex_int32_t yy_meta[44]
Definition: pycode.cpp:607
#define yytext_ptr
Definition: pycode.cpp:368
static char * yy_c_buf_p
Definition: pycode.cpp:297
static yyconst flex_int32_t yy_ec[256]
Definition: pycode.cpp:575
int yy_state_type
Definition: code.cpp:361
static yyconst flex_int16_t yy_chk[1769]
Definition: pycode.cpp:948
static yyconst flex_int16_t yy_def[574]
Definition: pycode.cpp:683
unsigned char YY_CHAR
Definition: code.cpp:357
static yyconst flex_int16_t yy_base[574]
Definition: pycode.cpp:616
register char * yy_cp
Definition: pycode.cpp:2243
#define YY_MORE_ADJ
Definition: pycode.cpp:1169
static int yy_start
Definition: pycode.cpp:299
#define YY_SC_TO_UI(c)
Definition: pycode.cpp:138
static yy_state_type * yy_state_buf
Definition: pycode.cpp:1149
static int yy_init_globals ( void  )
static

Definition at line 4002 of file pycode.cpp.

4003 {
4004  /* Initialization is the same as for the non-reentrant scanner.
4005  * This function is called from pycodeYYlex_destroy(), so don't allocate here.
4006  */
4007 
4008  (yy_buffer_stack) = 0;
4009  (yy_buffer_stack_top) = 0;
4010  (yy_buffer_stack_max) = 0;
4011  (yy_c_buf_p) = (char *) 0;
4012  (yy_init) = 0;
4013  (yy_start) = 0;
4014 
4015  (yy_start_stack_ptr) = 0;
4016  (yy_start_stack_depth) = 0;
4017  (yy_start_stack) = NULL;
4018 
4019  (yy_state_buf) = 0;
4020  (yy_state_ptr) = 0;
4021  (yy_full_match) = 0;
4022  (yy_lp) = 0;
4023 
4024 /* Defined in main.c */
4025 #ifdef YY_STDINIT
4026  pycodeYYin = stdin;
4027  pycodeYYout = stdout;
4028 #else
4029  pycodeYYin = (FILE *) 0;
4030  pycodeYYout = (FILE *) 0;
4031 #endif
4032 
4033  /* For future reference: Set errno on error, since we are called by
4034  * pycodeYYlex_init()
4035  */
4036  return 0;
4037 }
static char * yy_full_match
Definition: pycode.cpp:1150
static yy_state_type * yy_state_ptr
Definition: pycode.cpp:1149
static int yy_start_stack_depth
Definition: pycode.cpp:2134
static int * yy_start_stack
Definition: pycode.cpp:2135
FILE * pycodeYYout
Definition: pycode.cpp:359
static YY_BUFFER_STATE * yy_buffer_stack
Definition: pycode.cpp:274
static char * yy_c_buf_p
Definition: pycode.cpp:297
static int yy_lp
Definition: pycode.cpp:1151
static int yy_init
Definition: pycode.cpp:298
FILE * pycodeYYin
Definition: pycode.cpp:359
static size_t yy_buffer_stack_max
Definition: pycode.cpp:273
static int yy_start_stack_ptr
Definition: pycode.cpp:2133
static int yy_start
Definition: pycode.cpp:299
static size_t yy_buffer_stack_top
Definition: pycode.cpp:272
static yy_state_type * yy_state_buf
Definition: pycode.cpp:1149
static void yy_pop_state ( void  )
static

Definition at line 3882 of file pycode.cpp.

3883 {
3884  if ( --(yy_start_stack_ptr) < 0 )
3885  YY_FATAL_ERROR( "start-condition stack underflow" );
3886 
3888 }
static int * yy_start_stack
Definition: pycode.cpp:2135
static int yy_start_stack_ptr
Definition: pycode.cpp:2133
#define BEGIN
Definition: pycode.cpp:144
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
static void yy_push_state ( int  new_state)
static

Definition at line 3858 of file pycode.cpp.

3859 {
3861  {
3862  yy_size_t new_size;
3863 
3865  new_size = (yy_start_stack_depth) * sizeof( int );
3866 
3867  if ( ! (yy_start_stack) )
3868  (yy_start_stack) = (int *) pycodeYYalloc(new_size );
3869 
3870  else
3871  (yy_start_stack) = (int *) pycodeYYrealloc((void *) (yy_start_stack),new_size );
3872 
3873  if ( ! (yy_start_stack) )
3874  YY_FATAL_ERROR( "out of memory expanding start-condition stack" );
3875  }
3876 
3878 
3879  BEGIN(new_state);
3880 }
static int yy_start_stack_depth
Definition: pycode.cpp:2134
static int * yy_start_stack
Definition: pycode.cpp:2135
#define YY_START_STACK_INCR
Definition: pycode.cpp:2202
void * pycodeYYrealloc(void *, yy_size_t)
Definition: pycode.cpp:4097
static int yy_start_stack_ptr
Definition: pycode.cpp:2133
#define BEGIN
Definition: pycode.cpp:144
#define YY_START
Definition: pycode.cpp:150
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207
size_t yy_size_t
Definition: code.cpp:203
void * pycodeYYalloc(yy_size_t)
Definition: pycode.cpp:4092
static int yy_top_state ( void  )
static

Definition at line 3890 of file pycode.cpp.

3891 {
3892  return (yy_start_stack)[(yy_start_stack_ptr) - 1];
3893 }
static int * yy_start_stack
Definition: pycode.cpp:2135
static int yy_start_stack_ptr
Definition: pycode.cpp:2133
static yy_state_type yy_try_NUL_trans ( yy_state_type  current_state)
static

Definition at line 3379 of file pycode.cpp.

3380 {
3381  register int yy_is_jam;
3382 
3383  register YY_CHAR yy_c = 1;
3384  while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
3385  {
3386  yy_current_state = (int) yy_def[yy_current_state];
3387  if ( yy_current_state >= 540 )
3388  yy_c = yy_meta[(unsigned int) yy_c];
3389  }
3390  yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
3391  yy_is_jam = (yy_current_state == 539);
3392  if ( ! yy_is_jam )
3393  *(yy_state_ptr)++ = yy_current_state;
3394 
3395  return yy_is_jam ? 0 : yy_current_state;
3396 }
static yyconst flex_int16_t yy_nxt[1769]
Definition: pycode.cpp:750
static yy_state_type * yy_state_ptr
Definition: pycode.cpp:1149
static yyconst flex_int32_t yy_meta[44]
Definition: pycode.cpp:607
static yyconst flex_int16_t yy_chk[1769]
Definition: pycode.cpp:948
static yyconst flex_int16_t yy_def[574]
Definition: pycode.cpp:683
unsigned char YY_CHAR
Definition: code.cpp:357
static yyconst flex_int16_t yy_base[574]
Definition: pycode.cpp:616
static int yyread ( char *  buf,
int  max_size 
)
static

Definition at line 2013 of file pycode.cpp.

2014 {
2015  int c=0;
2016  while( c < max_size && g_inputString[g_inputPosition] )
2017  {
2018  *buf = g_inputString[g_inputPosition++] ;
2019  c++; buf++;
2020  }
2021  return c;
2022 }
static const char * g_inputString
the code fragment as text
Definition: pycode.cpp:1230
static int g_inputPosition
read offset during parsing
Definition: pycode.cpp:1231
static void yyunput ( int  c,
char *  buf_ptr 
)
static
static void yyunput ( int  c,
register char *  yy_bp 
)
static

Definition at line 3398 of file pycode.cpp.

3399 {
3400  register char *yy_cp;
3401 
3402  yy_cp = (yy_c_buf_p);
3403 
3404  /* undo effects of setting up pycodeYYtext */
3405  *yy_cp = (yy_hold_char);
3406 
3407  if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
3408  { /* need to shift things up to make room */
3409  /* +2 for EOB chars. */
3410  register int number_to_move = (yy_n_chars) + 2;
3411  register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
3412  YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
3413  register char *source =
3414  &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
3415 
3416  while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
3417  *--dest = *--source;
3418 
3419  yy_cp += (int) (dest - source);
3420  yy_bp += (int) (dest - source);
3421  YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
3422  (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
3423 
3424  if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
3425  YY_FATAL_ERROR( "flex scanner push-back overflow" );
3426  }
3427 
3428  *--yy_cp = (char) c;
3429 
3430  (yytext_ptr) = yy_bp;
3431  (yy_hold_char) = *yy_cp;
3432  (yy_c_buf_p) = yy_cp;
3433 }
static int yy_n_chars
Definition: pycode.cpp:293
#define yytext_ptr
Definition: pycode.cpp:368
static char * yy_c_buf_p
Definition: pycode.cpp:297
register char * yy_bp
Definition: pycode.cpp:2243
if(!(yy_init))
Definition: pycode.cpp:2251
static char yy_hold_char
Definition: pycode.cpp:292
#define YY_CURRENT_BUFFER_LVALUE
Definition: pycode.cpp:289
register char * yy_cp
Definition: pycode.cpp:2243
#define YY_FATAL_ERROR(msg)
Definition: pycode.cpp:2207

Variable Documentation

int g_bodyCurlyCount
static

Definition at line 1244 of file pycode.cpp.

QCString g_classScope
static

Definition at line 1246 of file pycode.cpp.

CodeOutputInterface* g_code
static

Definition at line 1229 of file pycode.cpp.

ClassSDict g_codeClassSDict(17)
static
bool g_collectXRefs
static

Definition at line 1235 of file pycode.cpp.

QStrList g_curClassBases
static

Definition at line 1226 of file pycode.cpp.

QCString g_curClassName
static

Definition at line 1225 of file pycode.cpp.

Definition* g_currentDefinition
static

Definition at line 1239 of file pycode.cpp.

const char* g_currentFontClass
static

Definition at line 1232 of file pycode.cpp.

MemberDef* g_currentMemberDef
static

Definition at line 1240 of file pycode.cpp.

QCString g_docBlock
static

contents of all lines of a documentation block

Definition at line 1263 of file pycode.cpp.

bool g_doubleQuote
static

Definition at line 1257 of file pycode.cpp.

bool g_doubleStringIsDoc
static

Definition at line 1256 of file pycode.cpp.

bool g_endComment
static

Definition at line 1264 of file pycode.cpp.

bool g_exampleBlock
static

Definition at line 1250 of file pycode.cpp.

QCString g_exampleName
static

Definition at line 1251 of file pycode.cpp.

bool g_includeCodeFragment
static

Definition at line 1241 of file pycode.cpp.

QValueStack<uint> g_indents
static

Tracks indentation levels for scoping in python.

Definition at line 1261 of file pycode.cpp.

int g_inputLines
static

number of line in the code fragment

Definition at line 1236 of file pycode.cpp.

int g_inputPosition
static

read offset during parsing

Definition at line 1231 of file pycode.cpp.

const char* g_inputString
static

the code fragment as text

Definition at line 1230 of file pycode.cpp.

QCString g_name
static

Definition at line 1254 of file pycode.cpp.

bool g_needsTermination
static

Definition at line 1233 of file pycode.cpp.

bool g_noSuiteFound
static

Definition at line 1258 of file pycode.cpp.

int g_paramParens
static

Definition at line 1247 of file pycode.cpp.

QCString g_realScope
static

Definition at line 1242 of file pycode.cpp.

Definition* g_searchCtx
static

Definition at line 1234 of file pycode.cpp.

bool g_searchingForBody
static

Definition at line 1245 of file pycode.cpp.

FileDef* g_sourceFileDef
static

Definition at line 1238 of file pycode.cpp.

int g_stringContext
static

Definition at line 1259 of file pycode.cpp.

PyCallContext g_theCallContext
static

Definition at line 1444 of file pycode.cpp.

PyVariableContext g_theVarContext
static

Definition at line 1372 of file pycode.cpp.

QCString g_type
static

Definition at line 1253 of file pycode.cpp.

int g_yyLineNr
static

current line number

Definition at line 1237 of file pycode.cpp.

int pycodeYY_flex_debug = 0

Definition at line 1147 of file pycode.cpp.

FILE * pycodeYYin = (FILE *) 0

Definition at line 359 of file pycode.cpp.

int pycodeYYleng

Definition at line 294 of file pycode.cpp.

int pycodeYYlineno = 1

Definition at line 365 of file pycode.cpp.

FILE * pycodeYYout = (FILE *) 0

Definition at line 359 of file pycode.cpp.

char * pycodeYYtext

Definition at line 1171 of file pycode.cpp.

yyconst flex_int16_t yy_accept[541]
static

Definition at line 512 of file pycode.cpp.

yyconst flex_int16_t yy_acclist[1033]
static

Definition at line 394 of file pycode.cpp.

register int yy_act

Definition at line 2244 of file pycode.cpp.

yyconst flex_int16_t yy_base[574]
static

Definition at line 616 of file pycode.cpp.

register char * yy_bp

Definition at line 2243 of file pycode.cpp.

YY_BUFFER_STATE* yy_buffer_stack = 0
static

Stack as an array.

Definition at line 274 of file pycode.cpp.

size_t yy_buffer_stack_max = 0
static

capacity of stack.

Definition at line 273 of file pycode.cpp.

size_t yy_buffer_stack_top = 0
static

index of top of stack.

Definition at line 272 of file pycode.cpp.

char* yy_c_buf_p = (char *) 0
static

Definition at line 297 of file pycode.cpp.

yyconst flex_int16_t yy_chk[1769]
static

Definition at line 948 of file pycode.cpp.

register char* yy_cp

Definition at line 2243 of file pycode.cpp.

YY_DECL
Initial value:
{
register yy_state_type yy_current_state
int yy_state_type
Definition: code.cpp:361

The main scanner function which does all the work.

Definition at line 2241 of file pycode.cpp.

yyconst flex_int16_t yy_def[574]
static

Definition at line 683 of file pycode.cpp.

int yy_did_buffer_switch_on_eof
static

Definition at line 304 of file pycode.cpp.

yyconst flex_int32_t yy_ec[256]
static

Definition at line 575 of file pycode.cpp.

int yy_full_lp
static

Definition at line 1153 of file pycode.cpp.

char* yy_full_match
static

Definition at line 1150 of file pycode.cpp.

int* yy_full_state
static

Definition at line 1154 of file pycode.cpp.

char yy_hold_char
static

Definition at line 292 of file pycode.cpp.

int yy_init = 0
static

Definition at line 298 of file pycode.cpp.

int yy_looking_for_trail_begin = 0
static

Definition at line 1152 of file pycode.cpp.

int yy_lp
static

Definition at line 1151 of file pycode.cpp.

yyconst flex_int32_t yy_meta[44]
static
Initial value:
=
{ 0,
1, 2, 3, 4, 5, 4, 5, 6, 2, 4,
7, 8, 2, 9, 9, 9, 9, 9, 9, 10,
9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
9, 9, 9
}

Definition at line 607 of file pycode.cpp.

int yy_n_chars
static

Definition at line 293 of file pycode.cpp.

yyconst flex_int16_t yy_nxt[1769]
static

Definition at line 750 of file pycode.cpp.

int yy_start = 0
static

Definition at line 299 of file pycode.cpp.

int* yy_start_stack = NULL
static

Definition at line 2135 of file pycode.cpp.

int yy_start_stack_depth = 0
static

Definition at line 2134 of file pycode.cpp.

int yy_start_stack_ptr = 0
static

Definition at line 2133 of file pycode.cpp.

yy_state_type* yy_state_buf =0
static

Definition at line 1149 of file pycode.cpp.

yy_state_type * yy_state_ptr =0
static

Definition at line 1149 of file pycode.cpp.