Can we fix this?
jfondren
julian.fondren at gmail.com
Wed Sep 29 16:44:12 UTC 2021
On Wednesday, 29 September 2021 at 16:23:34 UTC, Imperatorn wrote:
> Should we
What 'we' have been doing for 13 years is to have this bugzilla
link that documents the bug, and that it is a bug, with some
commentary on it, including a workaround.
I'm not prepared to fix the bug, and per Lindy's Law the bug
should get fixed in 2034, so *my* interest is
1. I'd like to not get surprised by this bug,
2. I'd like to have a reliable workaround for the bug.
And those would've been satisfied with documentation. Something
that's been the case for 13 years should just be in the spec with
its workaround. People read the spec and expect to know the
language; they don't read all of bugzilla. It's not like it's
hard to edit the spec when the bug is fixed.
Also, once you expect users to anticipate when they'll need the
workaround, this objection becomes lighter: "People have made it
clear they don't particularly like hidden allocations in
innocuous looking code. Hence the genesis of the @nogc attribute.
For this particular issue, it would be hard to look at a random
loop and see if allocations are occurring - i.e. a nasty surprise
if a small change suddenly made a big hit in performance.
Profiling is not the answer, as very, very few people profile
code."
As those random loops where allocations occur are precisely the
loops that need the workaround.
> fix the language or have best practices/documentation on how to
> "work around" the problem.
More information about the Digitalmars-d
mailing list