forked from chakra-core/ChakraCore
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWasmDataSegment.cpp
More file actions
33 lines (25 loc) · 857 Bytes
/
WasmDataSegment.cpp
File metadata and controls
33 lines (25 loc) · 857 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
//-------------------------------------------------------------------------------------------------------
// Copyright (C) Microsoft Corporation and contributors. All rights reserved.
// Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
//-------------------------------------------------------------------------------------------------------
#include "WasmReaderPch.h"
#ifdef ENABLE_WASM
namespace Wasm
{
WasmDataSegment::WasmDataSegment(ArenaAllocator* alloc, WasmNode ie, uint32 _source_size, const byte* _data) :
m_alloc(alloc),
m_initExpr(ie),
m_sourceSize(_source_size),
m_data(_data)
{
}
uint32 WasmDataSegment::GetSourceSize() const
{
return m_sourceSize;
}
const byte* WasmDataSegment::GetData() const
{
return m_data;
}
} // namespace Wasm
#endif // ENABLE_WASM