Complexity Changes by Version#
Every built-in function has a complexity cost, charged against a script’s complexity limit. Several built-ins get cheaper (rarely, more expensive) at a later standard library version, with no change to their arguments or return type, so a script recompiled at a higher STDLIB_VERSION can pass where it previously failed the complexity limit, with no code change.
Note
Generated from node-scala commit 104ddc70e8 by docs/scripts/generate_ride_reference.py. The generator reads the compiled standard library the node evaluates scripts with, not the Scala source text, so every cost on this page is the one the node charges. To change this page, change the generator or move it to a newer node-scala commit and regenerate. CI fails on any hand edit.
The table lists every function whose cost differs anywhere between V5 and V9: 74 rows, one per overload. A dash means the function does not exist at that version. Functions that are new in V6 to V9 appear here only if their cost changes after they are added; for everything a version adds, see Standard Library Versions, and for the full list of functions and costs at one version, see the function reference.
Function |
V5 |
V6 |
V7 |
V8 |
V9 |
|---|---|---|---|---|---|
|
64 |
64 |
64 |
1 |
1 |
|
64 |
64 |
64 |
1 |
1 |
|
8 |
8 |
8 |
1 |
1 |
|
20 |
1 |
1 |
1 |
1 |
|
8 |
8 |
8 |
1 |
1 |
|
8 |
8 |
8 |
1 |
1 |
|
64 |
64 |
64 |
1 |
1 |
|
8 |
8 |
8 |
1 |
1 |
|
8 |
8 |
8 |
1 |
1 |
|
63 |
1 |
1 |
1 |
1 |
|
200 |
136 |
136 |
136 |
136 |
|
100 |
115 |
115 |
115 |
115 |
|
10 |
13 |
13 |
13 |
13 |
|
25 |
29 |
29 |
29 |
29 |
|
50 |
58 |
58 |
58 |
58 |
|
30 |
30 |
30 |
30 |
3 |
|
6 |
6 |
6 |
6 |
2 |
|
20 |
20 |
20 |
20 |
2 |
|
6 |
6 |
6 |
6 |
2 |
|
20 |
20 |
20 |
20 |
2 |
|
128 |
1 |
1 |
1 |
1 |
|
128 |
1 |
1 |
1 |
1 |
|
14 |
1 |
1 |
1 |
1 |
|
17 |
1 |
1 |
1 |
1 |
|
10 |
10 |
10 |
10 |
4 |
|
40 |
40 |
40 |
40 |
12 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
2 |
2 |
2 |
2 |
1 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
4 |
4 |
4 |
4 |
2 |
|
200 |
195 |
195 |
195 |
195 |
|
100 |
147 |
147 |
147 |
147 |
|
10 |
20 |
20 |
20 |
20 |
|
25 |
39 |
39 |
39 |
39 |
|
50 |
74 |
74 |
74 |
74 |
|
30 |
1 |
1 |
1 |
1 |
|
192 |
192 |
192 |
6 |
6 |
|
160 |
160 |
160 |
35 |
35 |
|
192 |
192 |
192 |
6 |
6 |
|
65 |
65 |
65 |
1 |
1 |
|
65 |
65 |
65 |
1 |
1 |
|
200 |
270 |
270 |
270 |
270 |
|
100 |
28 |
28 |
28 |
28 |
|
7 |
7 |
7 |
4 |
1 |
|
— |
— |
— |
4 |
1 |
|
200 |
118 |
118 |
118 |
36 |
|
100 |
93 |
93 |
93 |
32 |
|
10 |
12 |
12 |
12 |
5 |
|
25 |
23 |
23 |
23 |
9 |
|
50 |
47 |
47 |
47 |
17 |
|
200 |
180 |
180 |
180 |
180 |
|
172 |
150 |
150 |
150 |
150 |
|
57 |
50 |
50 |
50 |
50 |
|
70 |
64 |
64 |
64 |
64 |
|
102 |
93 |
93 |
93 |
93 |
|
47 |
43 |
43 |
43 |
43 |
|
2 |
2 |
2 |
2 |
1 |
|
75 |
1 |
1 |
1 |
1 |
|
6 |
6 |
6 |
6 |
2 |
|
20 |
20 |
20 |
20 |
2 |
|
6 |
6 |
6 |
6 |
2 |
|
20 |
20 |
20 |
20 |
2 |
|
10 |
10 |
10 |
10 |
4 |
|
35 |
35 |
35 |
35 |
3 |
|
65 |
65 |
65 |
1 |
1 |
|
65 |
65 |
65 |
1 |
1 |
|
65 |
65 |
65 |
1 |
1 |
|
10 |
1 |
1 |
1 |
1 |
|
65 |
1 |
1 |
1 |
1 |
Where a function’s argument types are written differently at different versions, the row shows the newest spelling. For example, rsaVerify takes the digest algorithm as RsaDigestAlgs up to V5 and as the equivalent spelled-out union from V6.