[Issue 12251] New: Use of BigInts in triple operator too

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Feb 25 04:58:56 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=12251

           Summary: Use of BigInts in triple operator too
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Phobos
        AssignedTo: nobody at puremagic.com
        ReportedBy: bearophile_hugs at eml.cc


--- Comment #0 from bearophile_hugs at eml.cc 2014-02-25 04:58:55 PST ---
import std.stdio, std.bigint;
bool b;
void main() {
    int x1, x2;
    (b ? x1 : x2) += 1;
    writeln(x1, " ", x2);
    BigInt y1, y2;
    (b ? y1 : y2) += 1;
    writeln(y1, " ", y2);
}


Output:
0 1
0 0


Expected output:
0 1
0 1

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list