mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 06:41:48 +00:00
Push macro-parsing error calculation out of fundamental queries
This commit is contained in:
parent
067d9d995b
commit
56552f4839
15 changed files with 145 additions and 140 deletions
|
@ -132,13 +132,13 @@ pub enum ExpandError {
|
|||
MacroDefinition,
|
||||
Mbe(mbe::ExpandError),
|
||||
RecursionOverflow,
|
||||
Other(Box<Box<str>>),
|
||||
ProcMacroPanic(Box<Box<str>>),
|
||||
Other(Arc<Box<str>>),
|
||||
ProcMacroPanic(Arc<Box<str>>),
|
||||
}
|
||||
|
||||
impl ExpandError {
|
||||
pub fn other(msg: impl Into<Box<str>>) -> Self {
|
||||
ExpandError::Other(Box::new(msg.into()))
|
||||
ExpandError::Other(Arc::new(msg.into()))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue