blob: f87f2427817c17cf32207bce2a7ac28a7cbded91 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
import { Bind, DefineEffect, Effect, Kind1 } from '../stdlib/effect'
import { Print } from '../stdlib/stdio'
interface Mathemagic<_A, _B> extends Effect {}
interface PrintK extends Kind1 {
return: Print<this['input']>
}
export type main = [
DefineEffect<
'Mathemagic',
`(a, b) => {
console.log(typeToString(a))
return { result: 5 * b.getLiteralValue() }
}`
>,
Bind<Mathemagic<'a', 69>, PrintK>
]
|