blob: 4da23532181ccffa996ca521be8a27653e09c298 (
plain) (
blame)
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
|
(
(let config (DataSource 'config))
(let world (Configure! world config 'PureDataSource 'yt))
(let res_sink (DataSink 'result))
# result is true for all tests below
# To float
(let value (Uint64 '18446744073709551615))
(let commonType (DataType 'Float))
(let imlicitEqualsResult (Exists (StrictCast value commonType)))
(let world (Write! world res_sink (Key) imlicitEqualsResult '('('type))))
# To double
(let value (Int64 '"-9223372036854775808"))
(let commonType (DataType 'Double))
(let imlicitEqualsResult (Exists (StrictCast value commonType)))
(let world (Write! world res_sink (Key) imlicitEqualsResult '('('type))))
# To string
(let value (Utf8 '"проверка"))
(let commonType (DataType 'String))
(let imlicitEqualsResult (Exists (StrictCast value commonType)))
(let world (Write! world res_sink (Key) imlicitEqualsResult '('('type))))
(let world (Commit! world res_sink))
(return world)
)
|