-
-
Notifications
You must be signed in to change notification settings - Fork 411
Make deprecation warnings compile errors #1982
Conversation
|
Thanks for your pull request, @wilzbach! Bugzilla references
Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub fetch digger
dub run digger -- build "master + druntime#1982" |
|
Sounds good, currently fails CI though. |
Yeah: Easy to fix. That one turns out to be rather difficult as it appears deep in the |
c9eeea7 to
e74740f
Compare
e74740f to
dc7738d
Compare
|
Updated to resolve the merge conflicts and incorporate newer deprecations. |
dc7738d to
ba520a3
Compare
ba520a3 to
95c6043
Compare
ac588cb to
b53d839
Compare
350c467 to
2c03d72
Compare
2c03d72 to
b39d5d1
Compare
| alias UT = Args[idx - 1]; | ||
| enum op = Args[idx][1 .. $]; | ||
| static if (is(typeof((UT a) => mixin(op ~ " a")) RT == return)) | ||
| static if (is(typeof((UT a) => mixin(op ~ "cast(int) a")) RT == return)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could also have used -preview=intpromote here, but as this wouldn't be there when any user code tries to use this, I went with the "safe" approach of explicitly using the existing behavior.
|
@thewilsonator @JinShil FYI - this is passing and ready ;-) |
|
Heads up: this PR has caused a regression in my code. Trying to reduce it to minimal case now, will post details once I reduced it. |
|
Regression filed: https://issues.dlang.org/show_bug.cgi?id=19796 This PR broke array ops ( |
| { | ||
| auto op = arg[0] == 'u' ? arg[1 .. $] : arg; | ||
| stack[$ - 1] = op ~ stack[$ - 1]; | ||
| stack[$ - 1] = op ~ "cast(int)"~ stack[$ - 1]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the culprit. Deleting "cast(int)"~ fixes the problem.
I think there's a missing check that Args contains integral types! The cast causes problems when performing array ops on double[].
Thanks -> #2550 |
This is already the way we build Phobos + Tools.
See also: dlang/phobos#5546
CC @ZombineDev @CyberShadow