Nim/tests/destructor
ringabout a137e50150
fixes #19291; implements wasMoved hook (#21303)
* fixes #19291; implements `wasMoved` hook

* basics

* checkpoint

* finish `wasMoved`

* add a test for #19291

* add documentation and changelog

* work `attachedWasMoved` with generics

* fixes optimizer

* register `=wasMoved`

* handle wasMoved magcis

* check another round

* some patches

* try `op == nil`

* nicer

* generate `wasMoved` before `destroy`

* try again

* fixes tests

* default wasMoved

* Update tests/destructor/tv2_cast.nim

* Update tests/destructor/tv2_cast.nim

* Update tests/arc/topt_refcursors.nim
2023-03-02 05:29:40 +01:00
..
const_smart_ptr.nim fixes #12766 2019-11-29 19:46:21 +01:00
helper.nim destructors: first step towards fixing #9617 (#10341) 2019-01-18 08:51:22 +01:00
nim.cfg disable sink inference, only enable it for the stdlib. Reason: better source code compatibility (#15105) 2020-07-28 19:18:46 +02:00
objFile.nim Fix destructor injections for global variables (#11230) 2019-05-13 08:28:33 +02:00
smart_ptr.nim make sink operator optional (#13068) 2020-01-17 11:44:06 +00:00
t5342.nim Fix global destructor injection for JS backend (#19797) 2022-05-23 06:17:32 +02:00
t7346.nim remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 (#16918) 2021-02-17 09:32:36 +01:00
t9440.nim close #9440 add testcase (#17316) 2021-03-09 22:50:17 -08:00
t12037.nim deprecate unsafeAddr; extend addr (#19373) 2022-01-16 11:08:38 +01:00
t16607.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
t17198.nim fixes #17198, DFA failure on large case stmts (#17210) 2021-03-02 10:32:43 +01:00
tarc.nim fixes #14983 (#15320) 2020-09-25 08:49:21 +02:00
tarc2.nim new implementations for --gc:orc (#14121) 2020-04-27 11:57:26 +02:00
tarc3.nim fixes #13195 (#13198) 2020-01-20 10:41:12 +01:00
tarctypesections.nim ARC: cycle detector (#12823) 2019-12-17 17:37:50 +01:00
tarray_indexing.nim deprecate unsafeAddr; extend addr (#19373) 2022-01-16 11:08:38 +01:00
tasync_prototype.nim arc optimizations (#13325) 2020-03-18 16:57:34 +01:00
tasync_prototype_cyclic.nim new implementations for --gc:orc (#14121) 2020-04-27 11:57:26 +02:00
tatomicptrs.nim defaults to ORC (#19972) 2022-09-23 13:05:05 +02:00
tbintree2.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
tcaseobj_transitions.nim deprecate newruntime (#17245) 2021-03-04 19:33:16 +01:00
tcast.nim make tests green again 2019-03-04 22:44:23 +01:00
tcomplexobjconstr.nim use doAssert in tests (#16486) 2020-12-28 14:13:21 +01:00
tconst_smart_ptr.nim fixes #12766 2019-11-29 19:46:21 +01:00
tconsume_twice.nim renamed '=' to '=copy' [backport:1.2] (#15585) 2020-10-15 12:52:30 +02:00
tcustomseqs.nim deprecate unsafeAddr; extend addr (#19373) 2022-01-16 11:08:38 +01:00
tcustomstrings.nim remove {.this.} pragma, deprecated since 0.19 (#20201) 2022-08-23 19:44:37 +02:00
tcycle1.nim new implementations for --gc:orc (#14121) 2020-04-27 11:57:26 +02:00
tcycle2.nim fixes a critical =trace generation bug (see test case) (#14140) 2020-04-27 22:20:14 +02:00
tcycle3.nim fixes #14159 [backport:1.2] 2020-05-02 22:31:19 +02:00
tdangingref_simple.nim fixes #11350 2019-07-07 17:17:14 +02:00
tdestructor.nim scoped memory management (#14790) 2020-07-04 07:37:24 +02:00
tdestructor3.nim fix #15825 (#15894) 2020-11-09 19:24:32 +01:00
tdestructor_too_late.nim testament spec: remove errmsg alias of errormsg (#16188) 2020-11-29 17:32:34 -08:00
tdont_return_unowned_from_owned.nim fixes #19795; fixes #11852; fixes #19974; remove parsing pipeline, Nim now parses the whole module at one time (#21379) 2023-02-22 20:34:20 +01:00
terror_module.nim destructors: first step towards fixing #9617 (#10341) 2019-01-18 08:51:22 +01:00
texceptions.nim ARC related bugfixes and refactorings (#12781) 2019-12-05 16:59:06 +01:00
texplicit_move.nim Fix destructor injections for global variables (#11230) 2019-05-13 08:28:33 +02:00
tfinalizer.nim Small improvements for string and char repr with gc:arc (#14400) 2020-05-20 12:54:04 +02:00
tgcdestructors.nim deprecate newruntime (#17245) 2021-03-04 19:33:16 +01:00
tgcleak4.nim ARC related bugfixes and refactorings (#12781) 2019-12-05 16:59:06 +01:00
tglobaldestructor.nim deprecate newruntime (#17245) 2021-03-04 19:33:16 +01:00
tgotoexceptions.nim --exception:goto switch for deterministic exception handling (#12977) 2020-01-01 10:01:49 +01:00
tgotoexceptions2.nim --exception:goto switch for deterministic exception handling (#12977) 2020-01-01 10:01:49 +01:00
tgotoexceptions3.nim --exception:goto switch for deterministic exception handling (#12977) 2020-01-01 10:01:49 +01:00
tgotoexceptions4.nim fixes #13782 (#13834) 2020-04-01 20:30:28 +02:00
tgotoexceptions5.nim Fix #14647 (#14776) 2020-06-28 17:47:47 +02:00
tgotoexceptions6.nim fixes #13436 (#13615) 2020-03-10 00:52:46 +01:00
tgotoexceptions7.nim Error -> Defect for defects (#13908) 2020-04-28 19:56:01 +02:00
tgotoexceptions8.nim fixes #14925 (#14947) 2020-07-09 17:24:23 +02:00
tinvalid_rebind.nim more destructor based changes (#10885) 2019-03-23 00:12:05 +01:00
tmatrix.nim fixes #15361 (#15401) 2020-09-24 15:41:45 +02:00
tmisc_destructors.nim An optimizer for ARC (#14962) 2020-07-15 23:00:06 +02:00
tmove_objconstr.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
tnewruntime_misc.nim Add use of Windows Wide CRT API for env. vars (#20084) 2022-08-20 04:30:11 -04:00
tnewruntime_strutils.nim Fixes #17450 (#17477) 2021-03-23 16:30:49 +01:00
tobjfield_analysis.nim fixes #11095 (#11104) 2019-04-25 07:59:34 +02:00
topt.nim make tests green again 2019-05-27 21:29:02 +02:00
topttree.nim fixes a severe bug of testament (#20832) 2022-11-17 09:38:07 +08:00
towned_binary_tree.nim deprecate newruntime (#17245) 2021-03-04 19:33:16 +01:00
tprevent_assign.nim renamed '=' to '=copy' [backport:1.2] (#15585) 2020-10-15 12:52:30 +02:00
tprevent_assign2.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
tprevent_assign3.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
trecursive.nim default threads on (#19368) 2022-07-06 13:06:41 +02:00
tselect.nim Fixes #13659 (#13674) 2020-03-17 16:36:38 +01:00
tsetjmp_raise.nim Error -> Defect for defects (#13908) 2020-04-28 19:56:01 +02:00
tsimpleclosure.nim deprecate newruntime (#17245) 2021-03-04 19:33:16 +01:00
ttuple.nim make megatest consistent with unjoined tests wrt newlines, honor newlines in output spec (#16151) 2020-11-28 09:09:31 +01:00
turn_destroy_into_finalizer.nim testament: joinable is now an explicit concept of a test spec 2018-12-11 21:23:24 +01:00
tuse_ownedref_after_move.nim new move analyser2 (#20471) 2022-10-01 16:46:51 +02:00
tuse_result_prevents_sinks.nim deprecate unsafeAddr; extend addr (#19373) 2022-01-16 11:08:38 +01:00
tv2_cast.nim fixes #19291; implements wasMoved hook (#21303) 2023-03-02 05:29:40 +01:00
tv2_raise.nim fix #14421 items uses lent T (#14447) 2020-05-29 17:10:59 +02:00
twasmoved_error.nim fixes #19291; implements wasMoved hook (#21303) 2023-03-02 05:29:40 +01:00
twidgets.nim contributing docs: symbols need package prefix; changed allocStats to nimAllocStats (#13247) 2020-01-25 09:27:29 +01:00
twidgets_unown.nim fix #14421 items uses lent T (#14447) 2020-05-29 17:10:59 +02:00