Thread overview
[phobos] Phobos broken by svn 2233.
Dec 27, 2010
Don Clugston
Dec 28, 2010
Don Clugston
December 27, 2010
Compiling with -unittest on all platforms yields:

std\algorithm.d(118): Error: variable
std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp5735 of type
struct HasPostblit uses this(this), which is not allowed in static
initialization

You can see this in the DAutoTester results.

Introduced in Phobos svn 2233
"Fixed unlisted bug in readf"
in which the line 118 was actually modified. An odd thing about this
error is that the build continues regardless, and the tests still
pass.
December 27, 2010
Can't reproduce on OSX. I built and unittested both the debug and release versions. Anyone willing to take a look at this issue on Windows?

Andrei

On 12/27/10 10:14 AM, Don Clugston wrote:
> Compiling with -unittest on all platforms yields:
>
> std\algorithm.d(118): Error: variable
> std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp5735 of type
> struct HasPostblit uses this(this), which is not allowed in static
> initialization
>
> You can see this in the DAutoTester results.
>
> Introduced in Phobos svn 2233
> "Fixed unlisted bug in readf"
> in which the line 118 was actually modified. An odd thing about this
> error is that the build continues regardless, and the tests still
> pass.
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
December 28, 2010
If it doesn't happen on OSX, that's very odd, since it shows up in
Brad's autotester results for both Win32 and Linux32, though in
different places on each.
Note that it does NOT stop the build, so it's quite easy to miss, you
have to scroll through the output. On Linux, it happens after:
Testing generated/linux/debug/unittest/std/range


On 28 December 2010 04:45, Andrei Alexandrescu <andrei at erdani.com> wrote:
> Can't reproduce on OSX. I built and unittested both the debug and release versions. Anyone willing to take a look at this issue on Windows?
>
> Andrei
>
> On 12/27/10 10:14 AM, Don Clugston wrote:
>>
>> Compiling with -unittest on all platforms yields:
>>
>> std\algorithm.d(118): Error: variable
>> std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp5735 of type
>> struct HasPostblit uses this(this), which is not allowed in static
>> initialization
>>
>> You can see this in the DAutoTester results.
>>
>> Introduced in Phobos svn 2233
>> "Fixed unlisted bug in readf"
>> in which the line 118 was actually modified. An odd thing about this
>> error is that the build continues regardless, and the tests still
>> pass.
>> _______________________________________________
>> phobos mailing list
>> phobos at puremagic.com
>> http://lists.puremagic.com/mailman/listinfo/phobos
>
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
>
December 28, 2010
Oh, I saw the message now. Must be some is() test. Will look into this tomorrow.

Andrei

On 12/27/10 11:59 PM, Don Clugston wrote:
> If it doesn't happen on OSX, that's very odd, since it shows up in
> Brad's autotester results for both Win32 and Linux32, though in
> different places on each.
> Note that it does NOT stop the build, so it's quite easy to miss, you
> have to scroll through the output. On Linux, it happens after:
> Testing generated/linux/debug/unittest/std/range
>
>
> On 28 December 2010 04:45, Andrei Alexandrescu<andrei at erdani.com>  wrote:
>> Can't reproduce on OSX. I built and unittested both the debug and release versions. Anyone willing to take a look at this issue on Windows?
>>
>> Andrei
>>
>> On 12/27/10 10:14 AM, Don Clugston wrote:
>>>
>>> Compiling with -unittest on all platforms yields:
>>>
>>> std\algorithm.d(118): Error: variable
>>> std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp5735 of type
>>> struct HasPostblit uses this(this), which is not allowed in static
>>> initialization
>>>
>>> You can see this in the DAutoTester results.
>>>
>>> Introduced in Phobos svn 2233
>>> "Fixed unlisted bug in readf"
>>> in which the line 118 was actually modified. An odd thing about this
>>> error is that the build continues regardless, and the tests still
>>> pass.
>>> _______________________________________________
>>> phobos mailing list
>>> phobos at puremagic.com
>>> http://lists.puremagic.com/mailman/listinfo/phobos
>>
>> _______________________________________________
>> phobos mailing list
>> phobos at puremagic.com
>> http://lists.puremagic.com/mailman/listinfo/phobos
>>
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
December 29, 2010
This looks like a bug in the compiler. This line:

alias typeof(fun(.ElementType!R.init)) ElementType;

causes the error message

std/algorithm.d(118): Error: variable std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp1067 of type struct HasPostblit uses this(this), which is not allowed in static initialization

but this line:

alias typeof({ return fun(.ElementType!R.init); }()) ElementType;

works. I don't see a reason for which the first should work but the second shouldn't. I gave myself five minutes to reproduce the bug in a shorter context, without success. (Cue Walter with the line "But it's dead easy!") So I'll commit but will leave the non-working code commented out along with a @@@BUG@@@ comment in case one of you wants to take a look.

Speaking of messages during compilation, what's the deal with this?

Warning: WhiteHole!(I_1) used assert(0) instead of Error for the
auto-implemented nothrow function I_1.bar
Warning: AutoImplement!(C_6) ignored variadic arguments to the
constructor C_6(...)


Andrei

On 12/27/10 11:59 PM, Don Clugston wrote:
> If it doesn't happen on OSX, that's very odd, since it shows up in
> Brad's autotester results for both Win32 and Linux32, though in
> different places on each.
> Note that it does NOT stop the build, so it's quite easy to miss, you
> have to scroll through the output. On Linux, it happens after:
> Testing generated/linux/debug/unittest/std/range
>
>
> On 28 December 2010 04:45, Andrei Alexandrescu<andrei at erdani.com>  wrote:
>> Can't reproduce on OSX. I built and unittested both the debug and release versions. Anyone willing to take a look at this issue on Windows?
>>
>> Andrei
>>
>> On 12/27/10 10:14 AM, Don Clugston wrote:
>>>
>>> Compiling with -unittest on all platforms yields:
>>>
>>> std\algorithm.d(118): Error: variable
>>> std.algorithm.Map!(result,Repeat!(HasPostblit)).Map.__tmp5735 of type
>>> struct HasPostblit uses this(this), which is not allowed in static
>>> initialization
>>>
>>> You can see this in the DAutoTester results.
>>>
>>> Introduced in Phobos svn 2233
>>> "Fixed unlisted bug in readf"
>>> in which the line 118 was actually modified. An odd thing about this
>>> error is that the build continues regardless, and the tests still
>>> pass.
>>> _______________________________________________
>>> phobos mailing list
>>> phobos at puremagic.com
>>> http://lists.puremagic.com/mailman/listinfo/phobos
>>
>> _______________________________________________
>> phobos mailing list
>> phobos at puremagic.com
>> http://lists.puremagic.com/mailman/listinfo/phobos
>>
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos