KJS::FunctionBodyNode

KJS::FunctionBodyNode Class Reference

#include <nodes.h>

Inherits KJS::BlockNode.

Inherited by KJS::ProgramNode.

Public Member Functions

 FunctionBodyNode (SourceElementsNode *)
 
void addFunDecl (const Identifier &ident, int attr, FuncDeclNode *funcDecl)
 
void addParam (const Identifier &ident)
 
void addSymbolOverwriteID (size_t id, const Identifier &ident, int attr)
 
void addVarDecl (const Identifier &ident, int attr, ExecState *exec)
 
const CodeBlock & code () const
 
CodeBlock & code ()
 
void compile (CodeType ctype, CompileType compType)
 
void compileIfNeeded (CodeType ctype, CompileType compType)
 
CompileType compileState () const
 
Completion execute (ExecState *exec)
 
unsigned flags () const
 
virtual void generateExecCode (CompileState *)
 
size_t * getFunctionLocalInfo ()
 
SymbolInfo * getLocalInfo ()
 
bool isCompiled () const
 
size_t lookupSymbolID (const Identifier &id) const
 
size_t numFunctionLocals () const
 
int numLocalsAndRegisters () const
 
size_t numParams () const
 
const IdentifierparamName (size_t pos) const
 
void reserveSlot (size_t id, bool shouldMark)
 
int sourceId ()
 
const UStringsourceURL ()
 
SymbolTable & symbolTable ()
 
bool tearOffAtEnd () const
 

Detailed Description

This AST node corresponds to the function body or top-level code in the AST, but is used to keep track of much of the information relevant to the whole function, such as parameter names and symbol tables.

This is because there are both function declarations and expressions, so there is no natural single place to put this stuff above the body

inherited by ProgramNode

Definition at line 1276 of file nodes.h.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sun May 31 2020 23:07:12 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.