TorqueScript  0.2
Public Member Functions | List of all members
TorqueScript::Instructions::CallBoundFunctionInstruction Class Reference

Calls a function that is bound to an object identified on the stack. More...

#include <instructions.hpp>

Inheritance diagram for TorqueScript::Instructions::CallBoundFunctionInstruction:
Inheritance graph
[legend]
Collaboration diagram for TorqueScript::Instructions::CallBoundFunctionInstruction:
Collaboration graph
[legend]

Public Member Functions

 CallBoundFunctionInstruction (const std::string &name, const std::size_t argc)
 Constructs a new instance of CallBoundFunctionInstruction. More...
 
virtual AddressOffsetType execute (std::shared_ptr< ExecutionState > state) override
 Main execution method of the instruction. This serves as our switching statement that determines how opcodes will behave. More...
 
virtual std::string disassemble () override
 Helper routine to produce a disassembly for this instruction.
 

Additional Inherited Members

- Public Attributes inherited from TorqueScript::Instructions::Instruction
std::string mComment
 Compiler generated comment, used for generating easier to follow disassembly.
 

Detailed Description

Calls a function that is bound to an object identified on the stack.

Constructor & Destructor Documentation

◆ CallBoundFunctionInstruction()

TorqueScript::Instructions::CallBoundFunctionInstruction::CallBoundFunctionInstruction ( const std::string &  name,
const std::size_t  argc 
)
inline

Constructs a new instance of CallBoundFunctionInstruction.

Parameters
nameThe name of the function to call.
argcThe number of arguments to pull from the stack when resolving the call.

Member Function Documentation

◆ execute()

virtual AddressOffsetType TorqueScript::Instructions::CallBoundFunctionInstruction::execute ( std::shared_ptr< ExecutionState state)
inlineoverridevirtual

Main execution method of the instruction. This serves as our switching statement that determines how opcodes will behave.

Parameters
stateThe current execution state to act upon.

Implements TorqueScript::Instructions::Instruction.


The documentation for this class was generated from the following file: