-
Notifications
You must be signed in to change notification settings - Fork 13k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Doesn't yet converge on a fixed point, but generally works. A better algorithm will come with the implementation of default type parameter fallback. If inference fails to determine an exact integral or floating point type, it will set the type to i32 or f64, respectively. Closes #16968
- Loading branch information
Showing
14 changed files
with
57 additions
and
54 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,5 @@ | |
|
||
fn main() { | ||
println!("{}", std::mem::size_of_val(&1)); | ||
//~^ ERROR cannot determine a type for this expression | ||
} | ||
|
This file contains 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
This file contains 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
This file contains 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
35 changes: 0 additions & 35 deletions
35
src/test/run-pass/traits-multidispatch-infer-convert-source-and-target.rs
This file was deleted.
Oops, something went wrong.
This file contains 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
53ece71
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.
saw approval from nikomatsakis
at https://github.com/cmr/rust/commit/53ece7158500e561c69d6e07160518f19d8beafd
53ece71
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.
merging cmr/rust/i32-fallback = 53ece71 into auto
53ece71
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.
status: {"merge_sha": "1f72db2b01b5fe7e2e9799a68b7c7212f5f6f046"}
53ece71
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.
cmr/rust/i32-fallback = 53ece71 merged ok, testing candidate = 1f72db2b
53ece71
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.
some tests failed:
failure: http://buildbot.rust-lang.org/builders/auto-mac-64-nopt-t/builds/2964
exception: http://buildbot.rust-lang.org/builders/auto-mac-32-opt/builds/2969
exception: http://buildbot.rust-lang.org/builders/auto-mac-64-opt/builds/2963
exception: http://buildbot.rust-lang.org/builders/auto-linux-32-opt/builds/2955
exception: http://buildbot.rust-lang.org/builders/auto-linux-32-nopt-t/builds/2954
exception: http://buildbot.rust-lang.org/builders/auto-linux-64-opt/builds/2957
exception: http://buildbot.rust-lang.org/builders/auto-linux-64-nopt-t/builds/2950
exception: http://buildbot.rust-lang.org/builders/auto-linux-64-x-android-t/builds/2947
exception: http://buildbot.rust-lang.org/builders/auto-win-32-opt/builds/2622
exception: http://buildbot.rust-lang.org/builders/auto-win-32-nopt-t/builds/2619
exception: http://buildbot.rust-lang.org/builders/auto-win-64-opt/builds/1458
exception: http://buildbot.rust-lang.org/builders/auto-win-64-nopt-t/builds/1449
53ece71
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.
saw approval from nikomatsakis
at https://github.com/cmr/rust/commit/53ece7158500e561c69d6e07160518f19d8beafd
53ece71
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.
merging cmr/rust/i32-fallback = 53ece71 into auto
53ece71
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.
status: {"merge_sha": "ee3c5957eaaf577bff895ce819447f7e40558a28"}
53ece71
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.
cmr/rust/i32-fallback = 53ece71 merged ok, testing candidate = ee3c595
53ece71
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.
all tests pass:
success: http://buildbot.rust-lang.org/builders/auto-mac-32-opt/builds/2971
success: http://buildbot.rust-lang.org/builders/auto-mac-64-opt/builds/2965
success: http://buildbot.rust-lang.org/builders/auto-mac-64-nopt-t/builds/2966
success: http://buildbot.rust-lang.org/builders/auto-linux-32-opt/builds/2957
success: http://buildbot.rust-lang.org/builders/auto-linux-32-nopt-t/builds/2956
success: http://buildbot.rust-lang.org/builders/auto-linux-64-opt/builds/2959
success: http://buildbot.rust-lang.org/builders/auto-linux-64-nopt-t/builds/2952
success: http://buildbot.rust-lang.org/builders/auto-linux-64-x-android-t/builds/2949
success: http://buildbot.rust-lang.org/builders/auto-win-32-opt/builds/2624
success: http://buildbot.rust-lang.org/builders/auto-win-32-nopt-t/builds/2621
success: http://buildbot.rust-lang.org/builders/auto-win-64-opt/builds/1460
success: http://buildbot.rust-lang.org/builders/auto-win-64-nopt-t/builds/1451
53ece71
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.
fast-forwarding master to auto = ee3c595
53ece71
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.
fast-forwarding master to auto = ee3c595