| A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | Q (default semantics) | Q.passByCopy | JSON.stringify | Structured Clone | Proposed default | Proposed.passByCopy | Proposed pass by construction | |||||||||||||
2 | Object | pass-by-promise? | shallow copy | deep copy (own non-function data props only, non-cyclic) | deep copy (own data props only, cyclic) | pass-by-reference | shallow copy | by construction | ||||||||||||
3 | Function | pass-by-proxy | ? | error | error | pass-by-reference | shallow copy if closed; else error | by construction | ||||||||||||
4 | Array | shallow copy? | shallow copy? | deep copy | deep copy | pass-by-reference | shallow copy | by construction | ||||||||||||
5 | Number | copy | copy | copy | copy | copy | copy | N/A | ||||||||||||
6 | String | copy | copy | copy | copy | copy | copy | N/A | ||||||||||||
7 | Boolean | copy | copy | copy | copy | copy | copy | N/A | ||||||||||||
8 | null | copy | copy | copy | copy | copy | copy | N/A | ||||||||||||
9 | undefined | copy | copy | error | copy | copy | copy | |||||||||||||
10 | ||||||||||||||||||||
11 | ||||||||||||||||||||
12 | ||||||||||||||||||||
13 | Deep copy = recursively copies the parts using the same pass-by-copy semantics (i.e. the copied object is guaranteed not to contain any more references to remote data) | |||||||||||||||||||
14 | Shallow copy = recursively copies the parts using the default semantics (i.e. the copied object may still contain references to remote data) | |||||||||||||||||||
15 | pass-by-promise = the receiving side receives a remote promise object | |||||||||||||||||||
16 | pass-by-proxy = the receiving side receives a function that calls the original and returns a promise for the result | |||||||||||||||||||
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 | ||||||||||||||||||||
94 | ||||||||||||||||||||
95 | ||||||||||||||||||||
96 | ||||||||||||||||||||
97 | ||||||||||||||||||||
98 | ||||||||||||||||||||
99 | ||||||||||||||||||||
100 | ||||||||||||||||||||