2023-08-20 15:05:48 -03:00
|
|
|
/*
|
|
|
|
|
* Copyright (c) 2023, Dan Klishch <danilklishch@gmail.com>
|
|
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#include "Function.h"
|
|
|
|
|
#include "AST/AST.h"
|
|
|
|
|
|
|
|
|
|
namespace JSSpecCompiler {
|
|
|
|
|
|
|
|
|
|
Function::Function(ExecutionContext* context, StringView name, Tree ast)
|
|
|
|
|
: m_context(context)
|
|
|
|
|
, m_name(name)
|
|
|
|
|
, m_ast(move(ast))
|
2023-08-20 00:17:06 -03:00
|
|
|
, m_return_value(make_ref_counted<VariableDeclaration>("$return"sv))
|
2023-08-20 15:05:48 -03:00
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|