www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 10135] New: core.bitop: btc, btr, btc is "pure" but have side effects

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=10135

           Summary: core.bitop: btc, btr, btc is "pure" but have side
                    effects
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: trivial
          Priority: P2
         Component: druntime
        AssignedTo: nobody puremagic.com
        ReportedBy: 4denizzz gmail.com



---
core.bitop: btc, btr, btc is "pure" but have side effects

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 22 2013
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=10135




 core.bitop: btc, btr, btc is "pure" but have side effects
What do you mean? They don't modify any globals. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
May 23 2013
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=10135


Alex Rønne Petersen <alex lycus.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |alex lycus.org
         Resolution|                            |INVALID



CEST ---
Yes, they are pure per the D definition. Even if a function mutates the memory
pointed to by a pointer given to the function, it is still pure because that
pointer is considered an input.

See: http://klickverbot.at/blog/2012/05/purity-in-d/

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