Why do "const inout" and "const inout shared" exist?

H. S. Teoh via Digitalmars-d digitalmars-d at puremagic.com
Wed Jul 5 17:25:53 PDT 2017


On Tue, Jul 04, 2017 at 12:30:20AM -0700, Walter Bright via Digitalmars-d wrote:
> On 7/3/2017 5:29 PM, H. S. Teoh via Digitalmars-d wrote:
> > So what stops us from actually exploiting them in dmd's optimizer?
> 
> Nothing. Pull requests are welcome!

Sure, but it would be helpful if we knew what are some of the things
about D semantics that the optimizer could take advantage of, that it
currently doesn't yet.  Do you have a (not necessarily complete) list
somewhere?


T

-- 
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. -- Brian W. Kernighan


More information about the Digitalmars-d mailing list