We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 91a2f80 + 2a3b842 commit 746792fCopy full SHA for 746792f
rust/messages.py
@@ -1065,9 +1065,13 @@ def find_span_r(span, expansion=None):
1065
1066
# Add a message for macro invocation site if available in the local
1067
# crate.
1068
+ #
1069
+ # `macro_decl_name` can be a variety of things, like fn-like macro,
1070
+ # attribute, derive, "desugaring of", etc. We can generally only
1071
+ # handle macro_rules macros.
1072
if span['expansion'] and \
1073
not _is_external(window, span['file_name']) and \
- not span['expansion']['macro_decl_name'].startswith('#['):
1074
+ span['expansion']['macro_decl_name'].endswith('!'):
1075
invoke_span, expansion = find_span_r(span)
1076
# TODO: rustc now emits this in its text output in some cases.
1077
# Consider trying to avoid the duplicate note.
0 commit comments