Closure management.
More...
#include <Closure.hpp>
Closure management.
Definition at line 35 of file Closure.hpp.
◆ Closure() [1/2]
Construct a new Closure object.
- Parameters
-
scope | the scope of the function turned into a closure |
pa | the current page address of the function turned into a closure |
Definition at line 10 of file Closure.cpp.
◆ Closure() [2/2]
Construct a new Closure object.
- Parameters
-
scope_ptr | a shared pointer to the scope of the function turned into a closure |
pa | the current page address of the function turned into a closure |
Definition at line 15 of file Closure.cpp.
◆ hasFieldEndingWith()
bool Ark::internal::Closure::hasFieldEndingWith |
( |
const std::string & | end, |
|
|
const VM & | vm ) const |
|
nodiscard |
Used when generating error messages in the VM, to see if a symbol might have been wrongly fully qualified.
- Parameters
-
- Returns
- true if the closure has a field which is the end of 'end'
Definition at line 20 of file Closure.cpp.
References m_scope.
Referenced by Ark::VM::safeRun().
◆ pageAddr()
PageAddr_t Ark::internal::Closure::pageAddr |
( |
| ) |
const |
|
inlinenodiscard |
- Returns
- PageAddr_t the bytecode page address this closure refers to
Definition at line 61 of file Closure.hpp.
References m_page_addr.
◆ refScope()
◆ scope()
const ClosureScope & Ark::internal::Closure::scope |
( |
| ) |
const |
|
inlinenodiscardnoexcept |
◆ scopePtr()
const std::shared_ptr< ClosureScope > & Ark::internal::Closure::scopePtr |
( |
| ) |
const |
|
inlinenodiscard |
◆ toString()
std::string Ark::internal::Closure::toString |
( |
VM & | vm | ) |
const |
|
noexcept |
◆ operator<
◆ operator==
◆ m_page_addr
◆ m_scope
std::shared_ptr<ClosureScope> Ark::internal::Closure::m_scope |
|
private |
The documentation for this class was generated from the following files:
- /Users/fola/Documents/ArkScript/Ark/include/Ark/VM/Value/Closure.hpp
- /Users/fola/Documents/ArkScript/Ark/src/arkreactor/VM/Value/Closure.cpp