summary refs log tree commit diff stats
path: root/tests/destructor/tnonvardestructor.nim
Commit message (Collapse)AuthorAgeFilesLines
* fixes #22286; enforce Non-var T destructors by `nimPreviewNonVarDestructor` ↵ringabout2023-11-251-2/+29
| | | | | | | | | | | | | | | | | | (#22975) fixes #22286 ref https://forum.nim-lang.org/t/10642 For backwards compatibilities, we might need to keep the changes under a preview compiler flag. Let's see how many packags it break. **TODO** in the following PRs - [ ] Turn the `var T` destructors warning into an error with `nimPreviewNonVarDestructor` --------- Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
* fixes #22197; Distinct ref objects + destructor cause C++ codegen error (#22207)ringabout2023-07-021-1/+26
|
* allow destructors to accept non var parameters; deprecate `proc =destroy(x: ↵ringabout2023-06-211-0/+195
var T)` (#22130) * make destructors accept non var parameters * define nimAllowNonVarDestructor * add a test case and a changelog * update documentation and error messages * deprecate destructors taking 'var T'