Workaround Issue 11497 - lambda in "static if"/"assert" prevent inlining of functio#1688
Merged
1 commit merged intodlang:masterfrom Nov 18, 2013
monarchdodra:workaround11497
Merged
Workaround Issue 11497 - lambda in "static if"/"assert" prevent inlining of functio#16881 commit merged intodlang:masterfrom monarchdodra:workaround11497
1 commit merged intodlang:masterfrom
monarchdodra:workaround11497
Conversation
|
Auto-merge toggled on |
ghost
pushed a commit
that referenced
this pull request
Nov 18, 2013
Workaround Issue 11497 - lambda in "static if"/"assert" prevent inlining of functio
This pull request was closed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This little "trivial" change is all that is required for
emplaceto be always inlined at call site (regardless of-inlineswitch) with DMD.This gives drastic performance improvements for the likes of
array,Appender,Array.I had to use
lvalueOf!Arginstead ofArg.init, because the point of the test is to check for postblit, andArg.initspecifically bypasses it. I left in the old code, so we can revert if/when 11497 is fixed.