[Issue 5148] Incorrect C++ mangling of multiple const char* parameters

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Nov 12 09:24:41 PST 2010


http://d.puremagic.com/issues/show_bug.cgi?id=5148


Lukasz Wrzosek <luk.wrzosek at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #806 is|0                           |1
           obsolete|                            |


--- Comment #6 from Lukasz Wrzosek <luk.wrzosek at gmail.com> 2010-11-12 09:23:30 PST ---
Created an attachment (id=807)
Fix for bug 5148 and some other fixes.

This patch fixes also some other issues that I think weren't reported up to
now.
In gcc c++ functions with const arguments passed by value are mangled like not
const:
void Test(const int, const int) -> _Z4Testii
void Test(const char, const char) -> _Z4Testcc

struct MyStrutType { };
void Test(const MyStructType, const MyStructType) -> _Z4Test12MyStructTypeS_

enum MyEnumType { };
void Test(const MyEnumType, const MyEnumType) -> _Z4Test10MyEnumTypeS_

Without this patch dmd generates const versions.

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


More information about the Digitalmars-d-bugs mailing list