-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpkg.generated.mbti
More file actions
93 lines (72 loc) · 2.8 KB
/
Copy pathpkg.generated.mbti
File metadata and controls
93 lines (72 loc) · 2.8 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
// Generated using `moon info`, DON'T EDIT IT
package "oboard/eval"
import {
"moonbitlang/parser/syntax",
"oboard/eval/interpreter/core",
}
// Values
pub fn add_embedded_fn(MoonBitVM, String, (@core.RuntimeFunctionContext) -> @core.RuntimeValue raise @core.ControlFlow) -> Unit
pub fn add_embedded_method(MoonBitVM, String, String, (@core.RuntimeFunctionContext) -> @core.RuntimeValue raise @core.ControlFlow) -> Unit
pub fn add_extern_fn(MoonBitVM, String, (@core.RuntimeFunctionContext) -> @core.RuntimeValue raise @core.ControlFlow) -> Unit
pub fn code_to_ast(String) -> String
pub fn compile(MoonBitVM, String, params? : Array[String]) -> CompiledCode
pub fn eval_result_to_string(EvalResult) -> String
pub fn expr_to_string(@syntax.Expr) -> String
pub fn run_compiled(MoonBitVM, CompiledCode, args? : Array[&ToRuntime], log? : Bool) -> EvalResult
pub fn test_all(MoonBitVM, String, log? : Bool) -> TestResult
pub fn test_result_to_string(TestResult) -> String
pub fn value_to_json(@core.RuntimeValue) -> String
pub fn value_to_string(@core.RuntimeValue) -> String
// Errors
// Types and methods
pub(all) struct CompiledCode {
// private fields
}
pub fn CompiledCode::run(Self, MoonBitVM, args? : Array[&ToRuntime], log? : Bool) -> EvalResult
pub enum EvalResult {
Success(@core.RuntimeValue, @core.ClosureInterpreter)
Error(String, @core.ClosureInterpreter)
}
pub fn EvalResult::output(Self, &Logger) -> Unit
pub fn EvalResult::to_string(Self) -> String
pub impl Show for EvalResult
pub(all) struct MoonBitVM {
interpreter : @core.ClosureInterpreter
log : Bool
// private fields
}
#alias(new)
pub fn MoonBitVM::MoonBitVM(log? : Bool, modules? : Array[@core.RuntimeModule]) -> Self
pub fn MoonBitVM::compile(Self, String, params? : Array[String]) -> CompiledCode
pub fn MoonBitVM::create(log? : Bool, modules? : Array[@core.RuntimeModule]) -> Self
pub fn MoonBitVM::eval(Self, String, log? : Bool) -> EvalResult
pub fn MoonBitVM::run(Self, String, log? : Bool) -> Unit
pub fn MoonBitVM::test_all(Self, String, log? : Bool) -> TestResult
pub(all) struct TestFailure {
name : String
message : String
} derive(ToJson)
pub fn TestFailure::output(Self, &Logger) -> Unit
pub fn TestFailure::to_json(Self) -> Json
pub fn TestFailure::to_string(Self) -> String
pub impl Show for TestFailure
pub(all) struct TestResult {
total : Int
passed : Int
failed : Int
failures : Array[TestFailure]
} derive(ToJson)
pub fn TestResult::output(Self, &Logger) -> Unit
pub fn TestResult::to_json(Self) -> Json
pub fn TestResult::to_string(Self) -> String
pub impl Show for TestResult
// Type aliases
// Traits
pub(open) trait ToRuntime {
fn to_runtime(Self) -> @core.RuntimeValue
}
pub impl ToRuntime for Bool
pub impl ToRuntime for Int
pub impl ToRuntime for Double
pub impl ToRuntime for String
pub impl ToRuntime for @core.RuntimeValue