We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 157a12b commit 182f6e8Copy full SHA for 182f6e8
src/spanned.rs
@@ -93,7 +93,7 @@ use quote::spanned::Spanned as ToTokens;
93
/// See the [module documentation] for an example.
94
///
95
/// [module documentation]: self
96
-pub trait Spanned {
+pub trait Spanned: private::Sealed {
97
/// Returns a `Span` covering the complete contents of this syntax tree
98
/// node, or [`Span::call_site()`] if this node is empty.
99
@@ -106,3 +106,10 @@ impl<T: ?Sized + ToTokens> Spanned for T {
106
self.__span()
107
}
108
109
+
110
+mod private {
111
+ use super::*;
112
113
+ pub trait Sealed {}
114
+ impl<T: ?Sized + ToTokens> Sealed for T {}
115
+}
0 commit comments