Skip to content

Commit 964660a

Browse files
committed
No longer treat pointee as a builtin attribute
Also includes a drive-by typo fix
1 parent 8b2f6f8 commit 964660a

File tree

5 files changed

+1
-21
lines changed

5 files changed

+1
-21
lines changed

compiler/rustc_feature/src/builtin_attrs.rs

-6
Original file line numberDiff line numberDiff line change
@@ -578,12 +578,6 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
578578
EncodeCrossCrate::No, coroutines, experimental!(coroutines)
579579
),
580580

581-
// `#[pointee]` attribute to designate the pointee type in SmartPointer derive-macro
582-
gated!(
583-
pointee, Normal, template!(Word), ErrorFollowing,
584-
EncodeCrossCrate::No, derive_smart_pointer, experimental!(pointee)
585-
),
586-
587581
// RFC 3543
588582
// `#[patchable_function_entry(prefix_nops = m, entry_nops = n)]`
589583
gated!(

compiler/rustc_passes/messages.ftl

-4
Original file line numberDiff line numberDiff line change
@@ -584,10 +584,6 @@ passes_pass_by_value =
584584
`pass_by_value` attribute should be applied to a struct, enum or type alias
585585
.label = is not a struct, enum or type alias
586586
587-
passes_pointee_on_non_generic_ty =
588-
attribute should be applied to generic type parameters
589-
.label = not a generic type parameter
590-
591587
passes_proc_macro_bad_sig = {$kind} has incorrect signature
592588
593589
passes_remove_fields =

compiler/rustc_passes/src/check_attr.rs

-3
Original file line numberDiff line numberDiff line change
@@ -242,9 +242,6 @@ impl<'tcx> CheckAttrVisitor<'tcx> {
242242
[sym::coroutine, ..] => {
243243
self.check_coroutine(attr, target);
244244
}
245-
[sym::pointee, ..] => {
246-
self.check_pointee(attr, target);
247-
}
248245
[
249246
// ok
250247
sym::allow

compiler/rustc_passes/src/errors.rs

-7
Original file line numberDiff line numberDiff line change
@@ -643,13 +643,6 @@ pub struct CoroutineOnNonClosure {
643643
pub span: Span,
644644
}
645645

646-
#[derive(Diagnostic)]
647-
#[diag(passes_pointee_on_non_generic_ty)]
648-
pub struct PointeeOnNonGenericTy {
649-
#[primary_span]
650-
pub attr_span: Span,
651-
}
652-
653646
#[derive(Diagnostic)]
654647
#[diag(passes_empty_confusables)]
655648
pub(crate) struct EmptyConfusables {

compiler/rustc_resolve/src/ident.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ impl<'a, 'tcx> Resolver<'a, 'tcx> {
441441
}
442442
}
443443
Scope::DeriveHelpersCompat => {
444-
// FIXME: Try running this logic eariler, to allocate name bindings for
444+
// FIXME: Try running this logic earlier, to allocate name bindings for
445445
// legacy derive helpers when creating an attribute invocation with
446446
// following derives. Legacy derive helpers are not common, so it shouldn't
447447
// affect performance. It should also allow to remove the `derives`

0 commit comments

Comments
 (0)