Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
b59090e
Lower return type outside async block creation
Swatinem Nov 19, 2022
4e9ceef
Refactor `must_use` lint into two parts
Noratrieb Nov 13, 2022
1e4adaf
Fix CrateLocationUnknownType error
YC Nov 19, 2022
40b7e0e
Fix metadata_lib_filename_form
YC Nov 19, 2022
a1ea1c1
Check that library is file
YC Nov 19, 2022
644a5a3
enable fuzzy_provenance_casts lint in liballoc
RalfJung Nov 20, 2022
7f5addd
enable fuzzy_provenance_casts lint in libstd
RalfJung Nov 20, 2022
1a69666
dont attempt strict provenance in SGX
RalfJung Nov 21, 2022
2752e32
Allow opaque types in trait impl headers and rely on coherence to rej…
oli-obk Oct 24, 2022
94fe30f
Treat different opaque types of the same def id as equal during coher…
oli-obk Oct 27, 2022
ae80c76
Add an always-ambiguous predicate to make sure that we don't accident…
oli-obk Nov 2, 2022
9cd44f8
nit treat different opaque types
oli-obk Nov 14, 2022
9a8e1ee
Move a field around
oli-obk Nov 14, 2022
f42e490
Register obligations from type relation
oli-obk Nov 14, 2022
11ae334
Remove a function that doesn't actually do anything
oli-obk Nov 15, 2022
7301cd7
Type generalization should not look at opaque type in coherence
oli-obk Nov 17, 2022
11adf03
Add some more assertions for type relations not used during coherence
oli-obk Nov 17, 2022
c16a90f
Test generalization during coherence
oli-obk Nov 17, 2022
395f2b8
Remove extra . in metadata_lib_filename_form
YC Nov 22, 2022
7169c7d
Tests for bad --extern library path and file
YC Nov 22, 2022
ec41bc6
Rename `fn_trait_kind_from_{from_lang=>def_id}` to better convey meaning
WaffleLapkin Nov 22, 2022
632b96f
Remove `ty::ClosureKind::from_def_id`
WaffleLapkin Nov 22, 2022
d6f73c1
Add `TyCtxt::is_fn_trait`
WaffleLapkin Nov 22, 2022
e9f6db5
Simplify `ty::ClosureKind::extends`
WaffleLapkin Nov 22, 2022
3d407cc
micro doc fixes
WaffleLapkin Nov 22, 2022
48fee7a
Use `TyCtxt::is_fn_trait` is a couple more places
WaffleLapkin Nov 22, 2022
cd22ce6
Bump `fd-lock` in `bootstrap` again
mati865 Nov 22, 2022
8c1cec9
Rollup merge of #103488 - oli-obk:impl_trait_for_tait, r=lcnr
Manishearth Nov 23, 2022
38b8198
Rollup merge of #104359 - Nilstrieb:plus-one, r=fee1-dead
Manishearth Nov 23, 2022
cb4887b
Rollup merge of #104612 - Swatinem:async-ret-y, r=estebank
Manishearth Nov 23, 2022
ef3978d
Rollup merge of #104621 - YC:master, r=davidtwco
Manishearth Nov 23, 2022
8aa6ab8
Rollup merge of #104647 - RalfJung:alloc-strict-provenance, r=thomcc
Manishearth Nov 23, 2022
1f1bbfc
Rollup merge of #104732 - WaffleLapkin:from_def_idn't, r=compiler-errors
Manishearth Nov 23, 2022
b6c8794
Rollup merge of #104750 - mati865:bump-fd-lock-again, r=jyn514
Manishearth Nov 23, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use TyCtxt::is_fn_trait is a couple more places
  • Loading branch information
WaffleLapkin committed Nov 22, 2022
commit 48fee7a71d262d724a1f2af48b26a899b2a320fc
Original file line number Diff line number Diff line change
Expand Up @@ -399,10 +399,7 @@ impl<'tcx> NiceRegionError<'_, 'tcx> {
self_ty.highlight.maybe_highlighting_region(vid, actual_has_vid);

if self_ty.value.is_closure()
&& self
.tcx()
.fn_trait_kind_from_def_id(expected_trait_ref.value.def_id)
.is_some()
&& self.tcx().is_fn_trait(expected_trait_ref.value.def_id)
{
let closure_sig = self_ty.map(|closure| {
if let ty::Closure(_, substs) = closure.kind() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1769,8 +1769,7 @@ impl<'tcx> TypeErrCtxtExt<'tcx> for TypeErrCtxt<'_, 'tcx> {
.enumerate()
.find(|(other_idx, (pred, _))| match pred.kind().skip_binder() {
ty::PredicateKind::Trait(trait_pred)
if self.tcx.fn_trait_kind_from_def_id(trait_pred.def_id())
.is_some()
if self.tcx.is_fn_trait(trait_pred.def_id())
&& other_idx != idx
// Make sure that the self type matches
// (i.e. constraining this closure)
Expand Down