Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix Issue 19857 - Name mangling mismatch when compiling with -dip1000 #9789

Merged
merged 1 commit into from May 14, 2019

Conversation

WalterBright
Copy link
Member

No description provided.

@dlang-bot
Copy link
Contributor

dlang-bot commented May 14, 2019

Thanks for your pull request, @WalterBright!

Bugzilla references

Auto-close Bugzilla Severity Description
19857 blocker Name mangling mismatch when compiling with -dip1000

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub fetch digger
dub run digger -- build "stable + dmd#9789"

//pragma(msg, S.top.mangleof);

version (Win32)
static assert(S.top.mangleof == "_D4test__T5StackZQh3topMFNaNbNcNiNfZPi");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about other platforms?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The complete mangling varies slightly from platform to platform, but the issue under test does not, so one platform will suffice.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wilzbach That line needs to s/4test/10scopeinfer/

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed.

@jacob-carlborg
Copy link
Contributor

dlang-bot says this should target the stable branch. Otherwise, LGTM.

@wilzbach wilzbach changed the base branch from master to stable May 14, 2019 10:01
@jacob-carlborg
Copy link
Contributor

jacob-carlborg commented May 14, 2019

It's not a regression.

All bug fixes should target stable.

@wilzbach
Copy link
Member

But it's still blocking a lot of people using -dip1000 and we want to push it out as early as possible, hence I rebased to stable for you.
We can run merge_stable immediately afterwards.

@WalterBright
Copy link
Member Author

Oh, not again with the borked up git history.

@jacob-carlborg
Copy link
Contributor

Sebastian already changed to stable.

@jacob-carlborg
Copy link
Contributor

@WalterBright Sebastian fixed the commits for you. Don't push anything else.

@wilzbach
Copy link
Member

Sebastian already changed to stable.

Yup and I also rebased your commits. You reverted that my force-pushing over it. I restored it for you again.
For reference, rebasing to stable is as easy as:

git rebase --onto upstream/stable upstream/master 

(and changing the target branch to stable)

@dlang-bot dlang-bot merged commit 021c674 into dlang:stable May 14, 2019
@WalterBright WalterBright deleted the inferRetMangle branch May 14, 2019 12:10
fail_compilation/retscope.d(249): Error: cannot implicitly convert expression `__lambda1` of type `void* delegate() pure nothrow @nogc @safe` to `void* delegate() @safe`
fail_compilation/retscope.d(249): Error: cannot implicitly convert expression `__lambda1` of type `void* delegate() pure nothrow @nogc @safe` to `void* delegate() @safe`
fail_compilation/retscope.d(250): Error: cannot implicitly convert expression `__lambda2` of type `void* delegate() pure nothrow @nogc @safe` to `void* delegate() @safe`
fail_compilation/retscope.d(250): Error: cannot implicitly convert expression `__lambda2` of type `void* delegate() pure nothrow @nogc @safe` to `void* delegate() @safe`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That does not look good though. I'm all for the mangling change, but it shouldn't break the error message.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error message was changed because DMD used different mangling (and thus function names) with -preview=dip1000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants