/src/WasmEdge/include/host/mock/wasi_logging_func.h
Line | Count | Source (jump to first uncovered line) |
1 | | #pragma once |
2 | | |
3 | | #include "common/errcode.h" |
4 | | #include "host/mock/log.h" |
5 | | #include "runtime/callingframe.h" |
6 | | #include "runtime/hostfunc.h" |
7 | | |
8 | | namespace WasmEdge { |
9 | | namespace Host { |
10 | | namespace WasiLoggingMock { |
11 | | |
12 | | using namespace std::literals; |
13 | | |
14 | | class Log : public Runtime::HostFunction<Log> { |
15 | | public: |
16 | | Expect<void> body(const Runtime::CallingFrame &, uint32_t, uint32_t, uint32_t, |
17 | 0 | uint32_t, uint32_t) { |
18 | 0 | printPluginMock("wasi-logging"sv); |
19 | 0 | return Unexpect(ErrCode::Value::HostFuncError); |
20 | 0 | } |
21 | | }; |
22 | | |
23 | | } // namespace WasiLoggingMock |
24 | | } // namespace Host |
25 | | } // namespace WasmEdge |