Dmitry Olshansky via phobos
phobos at puremagic.com
Mon Oct 26 09:27:36 PDT 2015
On 26-Oct-2015 19:20, Andrei Alexandrescu wrote:
> On 10/26/15 12:08 PM, Dmitry Olshansky via phobos wrote:
>> On 26-Oct-2015 18:15, Andrei Alexandrescu via phobos wrote:
>>> Hi folks, isStringLike is a fine idea but there are a number of issues
>>> I noticed while looking at the PR and the related pieces it works with.
>>> I think a string-like structure is:
>>> (a) an array of characters or a subtype thereof
>>> (b) some other forward range with ElementType some character type, and
>>> potentially ElementEncodingType a different character type as well.
>> Sadly the main reason for isStringLike is
>> (c) alias this to something that has a or b defined above.
> Nonono, (a) includes that case ("... or a subtype thereof"). The point
> of "alias this" is it makes subtyping happen. Any failure to do so is
> a failure of "alias this" and needs fixing.
Agreed. That is my opinion as well, however luck of any attention from
you and Walter led to the point where we
need (a) and (b) to work right now and we hacked it (somewhat of
speaking for the community here, correct me if I'm wrong).
>> Release is unavoidable. Let us ship it then figure out the optimal
>> string like definition. The whole auto-decoding mess together with alias
>> this mess is important to solve but must not prevent us from releasing
>> on time.
> If we release now, we're stuck with isStringLike forever. Any chance
> of at least making it package?
I believed it was private/package hack. Anyhow we can redefine how
isStringLike exactly works as long as semantics stay sane.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3707 bytes
Desc: S/MIME Cryptographic Signature
More information about the phobos