Use cursor scope ptr to determine cursor provenance
diff --git a/src/buffer.rs b/src/buffer.rs
index 8c32645..a13d683 100644
--- a/src/buffer.rs
+++ b/src/buffer.rs
@@ -348,6 +348,10 @@
 }
 
 impl private {
+    pub fn same_scope(a: Cursor, b: Cursor) -> bool {
+        a.scope == b.scope
+    }
+
     #[cfg(procmacro2_semver_exempt)]
     pub fn open_span_of_group(cursor: Cursor) -> Span {
         match *cursor.entry() {