loom
135,55c35,36
2< Source: test/source/engine/debug/divide-by-zero.s-script
3< [ 1]fn div(int : x, int : y) -> int
4< [ 2]{
5< [ 3] return x/y
6< ^
7< [ 4]}
8< [ 5]
9<
10< Calls:
11< 0. fn div(int x, int y) -> int
12< Called from (f:1, l:6, h:, o:4):
13< Locals:
14< y = 0
15< x = 4
16<
17< <root module>
18< Call point is out
19< Locals:
20< div = <function>
21<
22< The work is paused
23---
24> <null>
25> The work is stopped
26Ошибка при выполнении теста test/mr-test-messaging-ipc-wrapper
27Тест работы IPC ====================================
28--- test/source/engine/debug/asynch-01.s-script :
29import "../import/asynch.s-script"
30: async
31def auto : factor = fn [factor] (int : x) -> int
32{
33if x <= 1 return 1
34return x*factor(x-1)
35}
36def auto : future = async.future( fn [factor] () { return factor(3) } )
37def int : f = factor(3)
38print f
39print f == future.get()
40--- interpret :
416
42true
43The work is stopped
44The work is completed
45--- test/source/engine/debug/divide-by-zero.s-script :
46fn div(int : x, int : y) -> int
47{
48return x/y
49}
50
51print div(4, 0)
52--- interpret :
53Ошибка: Произошло исключение при обработке оператора SBL
54Описание исключения: Деление на ноль
55Позиция разбора: test/source/engine/debug/divide-by-zero.s-script:3:13[3,14]
56<null>
57The work is stopped
58The work is completed
59--- test/source/engine/debug/fiber-01-primes-100.s-script :
60import "../import/primes.s-script" type Primes : p1
61make fiber p1
62flow fiber p1.prime(1,100)
63wait fiber p1
64--- interpret :
651
663
675
687
6911
7013
7117
7219
7323
7429
7531
7637
7741
7843
7947
8053
8159
8261
8367
8471
8573
8679
8783
8889
8997
90The work is stopped
91The work is completed
92