1
Fork 0

implement the basics of the lint static analysis

This commit is contained in:
Arthur Lafrance 2023-09-23 23:50:47 -07:00
parent 39164b84e0
commit 8769e02d0b
4 changed files with 41 additions and 0 deletions

View file

@ -212,6 +212,7 @@ impl Span {
/// This function is used as a fast path when decoding the full `SpanData` is not necessary.
/// It's a cut-down version of `data_untracked`.
#[rustc_diagnostic_item = "SpanCtxt"]
#[inline]
pub fn ctxt(self) -> SyntaxContext {
if self.len_with_tag_or_marker != BASE_LEN_INTERNED_MARKER {

View file

@ -303,6 +303,7 @@ symbols! {
SliceIndex,
SliceIter,
Some,
SpanCtxt,
String,
StructuralEq,
StructuralPartialEq,