Fix: #2604, Fix: #2240, Fix: #2341, Fix #1355 - Better error handling and and spaces handling in autofmt (#2736)
* add new autofmt sample * Feat: implement rustfmt::skip support for rsx * generally improve error handling with better expect messages * wip: nested rsx formatting and expression formatting * nested rsx formatting works * collapse autofmt crate * cast indent through macros * use proper whitespace * no more eating comments! * Use proper error handling
This commit is contained in:
1 parent
ef0202f999
commit
828cc502f1
47 files changed
+1621
-1055
No files matched your search
@@ -34,7 +34,7 @@ pub struct Component {
|
||||
pub fields: Vec<Attribute>,
|
||||
pub component_literal_dyn_idx: Vec<DynIdx>,
|
||||
pub spreads: Vec<Spread>,
|
||||
pub brace: token::Brace,
|
||||
pub brace: Option<token::Brace>,
|
||||
pub children: TemplateBody,
|
||||
pub dyn_idx: DynIdx,
|
||||
pub diagnostics: Diagnostics,
|
||||
@@ -69,8 +69,8 @@ impl Parse for Component {
|
||||
name,
|
||||
generics,
|
||||
fields,
|
||||
brace: Some(brace),
|
||||
component_literal_dyn_idx,
|
||||
brace,
|
||||
spreads,
|
||||
diagnostics,
|
||||
};
|
||||
@@ -308,7 +308,7 @@ impl Component {
|
||||
Component {
|
||||
name,
|
||||
generics,
|
||||
brace: token::Brace::default(),
|
||||
brace: None,
|
||||
fields: vec![],
|
||||
spreads: vec![],
|
||||
children: TemplateBody::new(vec![]),
|
||||
|
||||
Reference in new issue
Block a user