Phobos' std.conv.text functions

via Digitalmars-d digitalmars-d at puremagic.com
Mon Aug 31 10:03:16 PDT 2015


On Monday, 31 August 2015 at 15:39:10 UTC, H. S. Teoh wrote:
> On Mon, Aug 31, 2015 at 03:15:07PM +0000, via Digitalmars-d 
> wrote:
>> I have been bitten by the std.conv.text family of functions 
>> twice now and while it's not a major issue, I think it still 
>> an issue that is worth fixing and perhaps prevent similar 
>> issues in the future.
>> 
>> First time I got bitten was because of local imports shadowing 
>> local symbols without error or at least a warning.
>> 
>> auto stuff(string text) {
>>   import std.conv;
>> 
>>   foreach(ch; text.byDchar) {
>>   }
>> }
>
> https://issues.dlang.org/show_bug.cgi?id=10378
>
> Kenji has a pull for this, let's hope it goes through.
>
>
> T


Great! This PR seems to only fix the local import shadowing bug, 
though.


More information about the Digitalmars-d mailing list