www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 13735] New: Tests for dmd#3998 start fails after 2014-11-09

https://issues.dlang.org/show_bug.cgi?id=13735

          Issue ID: 13735

                    FreeBSD without obvious reasons.
           Product: D
           Version: D2
          Hardware: x86_64
                OS: FreeBSD
            Status: NEW
          Severity: regression
          Priority: P1
         Component: DMD
          Assignee: nobody puremagic.com
          Reporter: wazar.leollone yahoo.com

https://github.com/D-Programming-Language/dmd/pull/3998 starts to fail on
FreeBSD 64 (arm-2 server). 
Looks like it passes on 26b28ec564f7a8fb6f50487f6fe42a323a5e1392 phobos and
10451418ec52adb4bb6235fa7e56ae81e94d817a dmd (before merging this patch) but
stop passing on phobos 70d0a6dbae50684401ba8d3c4df27e0103717bf7 and dmd
dc118391e51ddb69093780c157b1ca41e26add90.

However it looks like it relevants with this PR (the funny thing)

****************
std/format.d(2304): Error: popFront (ref string str) is not callable using
argument types (C3)
std/format.d(2708): Error: template instance
std.format.formatRange!(Appender!string, C3, char) error instantiating
std/format.d(3300):        instantiated from here:
formatValue!(Appender!string, C3, char)
std/format.d(1897):        instantiated from here: formatTest!(C3)
*****************
In other words, the following code fails, ...
*******************
    class  C3 { string val; alias val this; this(string s){ val = s; }
                override string toString() const { return "C"; } }
    formatTest( new C3("c3"), "C" ); 
*******************
... because ref C3 can not be passed to function as ref string, even if C3.val
is l-value.
However this test is passed on the others platforms (as needed). This may be
(C++ compiler related issue, when my code contains a error, which manifested
only with this environment).
Is somebody knows, was arm-2 g++ updated near 2014-11-09? And is it possible to
tests this PR manually on another FreeBSD64?

--
Nov 14 2014