[Issue 20123] New: Impossible to disable post-increment/decrement semantics
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Aug 12 03:18:36 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=20123
Issue ID: 20123
Summary: Impossible to disable post-increment/decrement
semantics
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: turkeyman at gmail.com
D implements post-increment/decrement with a lowered expression.
According to the docs; (auto t = val, ++val, t)
I'm implementing C++'s atomic<T> type, which implements `operator++` &
`operator--`, but I realised that the lowering is not atomic, and I seem to
have no way to implement the post-inc/dec operators explicitly such that I can
make them atomic.
To properly implement this library, I need a way to implement the post-int/dec
operators explicitly.
--
More information about the Digitalmars-d-bugs
mailing list