[Issue 11837] String literals should convert to const(void)*

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Dec 28 08:33:30 PST 2013


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


bearophile_hugs at eml.cc changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bearophile_hugs at eml.cc


--- Comment #1 from bearophile_hugs at eml.cc 2013-12-28 08:33:27 PST ---
(In reply to comment #0)
> Code like this is perfectly valid:
> 
> memcmp(ptr, "abc");
> 
> But it fails in D because although string literals convert to const(char)*, and
> const(char)* converts to const(void)*, string literals do not convert to
> const(void)*

What are the advantages, disadvantages and possible risks of this change?

-- 
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