www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2985] New: Add enumToString and enumFromString to std.conv

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

           Summary: Add enumToString and enumFromString to std.conv
           Product: D
           Version: 2.029
          Platform: PC
        OS/Version: All
            Status: NEW
          Keywords: patch
          Severity: enhancement
          Priority: P2
         Component: Phobos
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: rsinfu gmail.com


Created an attachment (id=368)
 --> (http://d.puremagic.com/issues/attachment.cgi?id=368)
Adds enumToString and enumFromString

The patch adds new template functions enumToString and enumFromString to
std.conv. These functions convert between an enum member value and its name,
and do not require that enums should be defined by some template (cf.
defineEnum).

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


Andrei Alexandrescu <andrei metalanguage.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
                 CC|                            |andrei metalanguage.com
         AssignedTo|bugzilla digitalmars.com    |andrei metalanguage.com





05:08:13 PDT ---
Looks great! I'll add the functions and credit for you in std.conv. Thank you,
Shin!

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 16 2009
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2985


Andrei Alexandrescu <andrei metalanguage.com> changed:

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





21:14:21 PDT ---
I just merged Shin's implementation to std.conv and added his name to the list
of authors for the module. Instead of adding enumToString and enumFromString, I
had Shin's code replace the corresponding "to" functions directly. The feature
will be part of the next release.

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