Commit a69ab64
committed
feat: add explicit dispose() methods to JSSandbox and LoadedJSSandbox NAPI wrappers
Add #[napi] dispose() methods that eagerly release underlying sandbox
resources by calling take() on the inner Option. After disposal, all
subsequent calls return ERR_CONSUMED. No-op on already-consumed instances.
Signed-off-by: Simon Davies <simongdavies@users.noreply.github.com>1 parent a892a0a commit a69ab64
1 file changed
Lines changed: 28 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
801 | 801 | | |
802 | 802 | | |
803 | 803 | | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
804 | 818 | | |
805 | 819 | | |
806 | 820 | | |
| |||
1150 | 1164 | | |
1151 | 1165 | | |
1152 | 1166 | | |
| 1167 | + | |
| 1168 | + | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
| 1173 | + | |
| 1174 | + | |
| 1175 | + | |
| 1176 | + | |
| 1177 | + | |
| 1178 | + | |
| 1179 | + | |
| 1180 | + | |
1153 | 1181 | | |
1154 | 1182 | | |
1155 | 1183 | | |
| |||
0 commit comments