mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 20:42:04 +00:00
feat: ignored and disabled macro expansion
This commit is contained in:
parent
5e1b09bb76
commit
6d45afd8d8
8 changed files with 105 additions and 12 deletions
|
@ -129,6 +129,8 @@ pub type ExpandResult<T> = ValueResult<T, ExpandError>;
|
|||
#[derive(Debug, PartialEq, Eq, Clone, Hash)]
|
||||
pub enum ExpandError {
|
||||
UnresolvedProcMacro(CrateId),
|
||||
/// The macro expansion is disabled.
|
||||
MacroDisabled,
|
||||
Mbe(mbe::ExpandError),
|
||||
RecursionOverflowPoisoned,
|
||||
Other(Box<Box<str>>),
|
||||
|
@ -160,6 +162,7 @@ impl fmt::Display for ExpandError {
|
|||
f.write_str(it)
|
||||
}
|
||||
ExpandError::Other(it) => f.write_str(it),
|
||||
ExpandError::MacroDisabled => f.write_str("macro disabled"),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue