High-level wrapper for readline package
Nordlöw via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Thu Sep 7 12:38:38 PDT 2017
On Thursday, 7 September 2017 at 16:23:46 UTC, Adam D. Ruppe
wrote:
> On Thursday, 7 September 2017 at 16:18:09 UTC, bauss wrote:
>> Isn't it pointless to make "prompt" in?
>
> No, it promises the function isn't doing anything weird to it
> (modify, which immutable covers, but also scope.. .unless dmd
> changed that), which means a copy of the pointer won't be
> stored either. Important to realize with C cuz then you know it
> is ok to use a temporary to it.
But I believe it's ok to relax it from `string` to
`const(char)[]`, right?
More information about the Digitalmars-d-learn
mailing list