Thread overview
[Issue 9658] New: Setting pre-initialized field should be allowed in qualified constructor.
Mar 07, 2013
Kenji Hara
Mar 07, 2013
Kenji Hara
Mar 07, 2013
Kenji Hara
March 07, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9658

           Summary: Setting pre-initialized field should be allowed in
                    qualified constructor.
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: major
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: k.hara.pg@gmail.com


--- Comment #0 from Kenji Hara <k.hara.pg@gmail.com> 2013-03-06 18:34:54 PST ---
This code should work, but doesn't.

struct S
{
    private bool _isNull = true;
    this(int v) const
    {
        _isNull = false;    // cannot modify const expression this._isNull
    }
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 07, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9658


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull


--- Comment #1 from Kenji Hara <k.hara.pg@gmail.com> 2013-03-06 18:45:25 PST ---
https://github.com/D-Programming-Language/dmd/pull/1725

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 07, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9658



--- Comment #2 from github-bugzilla@puremagic.com 2013-03-06 19:58:51 PST ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/966e15b4fe8a08345fa77c1420399ca5c1657704
fix Issue 9658 - Setting pre-initialized field should be allowed in qualified
constructor.

https://github.com/D-Programming-Language/dmd/commit/d2d45966a6fdf5abfe30b3f4a2e26e3dc2e73b3d Merge pull request #1725 from 9rnsr/fix9658

Issue 9658 - Setting pre-initialized field should be allowed in qualified constructor.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 07, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9658


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


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