diff options
| author | Christian Krinitsin <mail@krinitsin.com> | 2025-07-17 09:10:43 +0200 |
|---|---|---|
| committer | Christian Krinitsin <mail@krinitsin.com> | 2025-07-17 09:10:43 +0200 |
| commit | f2ec263023649e596c5076df32c2d328bc9393d2 (patch) | |
| tree | 5dd86caab46e552bd2e62bf9c4fb1a7504a44db4 /results/scraper/fex/1678 | |
| parent | 63d2e9d409831aa8582787234cae4741847504b7 (diff) | |
| download | qemu-analysis-main.tar.gz qemu-analysis-main.zip | |
Diffstat (limited to 'results/scraper/fex/1678')
| -rw-r--r-- | results/scraper/fex/1678 | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/results/scraper/fex/1678 b/results/scraper/fex/1678 new file mode 100644 index 000000000..7c35c4c60 --- /dev/null +++ b/results/scraper/fex/1678 @@ -0,0 +1,15 @@ +Make object ownership, lifetime and non-nullable pointers more obvious +Follow up from #1671 from discussion with @neobrain + +> Better tracking allocation/free responsibilities, as well as nullable pointers would be an interesting code quality improvement. + +Myself I'm not much of a fan of C++ references, mostly because of the confusion they can create over what is a pointer and what is not, and I mostly use to rename locals in functions. The codebase mixes in pointers and references in arbitrary ways, which can create confusion. + +There's a couple of arguments for using more references, to communicate among other things +- non nullable uses +- pointer constness +- Allocation / Free semantics + +We could easily track these with some annotating templates, and avoid references, or we could go full in references and whatnot. + +Thoughts? |