From f9349edf77717a525ebe3cc06f780539b34d054c Mon Sep 17 00:00:00 2001 From: Greg Shuflin Date: Fri, 12 Nov 2021 01:13:13 -0800 Subject: [PATCH] run rustfmt --- schala-lang/language/src/parsing/test.rs | 34 +++++++++++------------- 1 file changed, 15 insertions(+), 19 deletions(-) diff --git a/schala-lang/language/src/parsing/test.rs b/schala-lang/language/src/parsing/test.rs index e22b458..3a46264 100644 --- a/schala-lang/language/src/parsing/test.rs +++ b/schala-lang/language/src/parsing/test.rs @@ -789,21 +789,18 @@ fn functions() { })))] ); - let source = r#" fn some_function() { }"#; - assert_ast2!(source, vec![fn_decl( - Signature { - name: rc("some_function"), - operator: false, - type_anno: None, - params: vec![] - }, + assert_ast2!( + source, + vec![fn_decl( + Signature { name: rc("some_function"), operator: false, type_anno: None, params: vec![] }, vec![].into() - )]); + )] + ); } #[test] @@ -906,20 +903,19 @@ fn impls() { use Declaration::{FuncDecl, Impl}; let block = vec![ - FuncDecl(Signature { name: rc("yolo"), operator: false, params: vec![], type_anno: None }, - vec![].into()), - FuncDecl(Signature { name: rc("swagg"), operator: false, params: vec![], type_anno: None }, - vec![].into() - ) + FuncDecl( + Signature { name: rc("yolo"), operator: false, params: vec![], type_anno: None }, + vec![].into(), + ), + FuncDecl( + Signature { name: rc("swagg"), operator: false, params: vec![], type_anno: None }, + vec![].into(), + ), ]; assert_ast2!( "impl Heh { fn yolo() { }; fn swagg() { } }", - vec![decl(Impl { - type_name: ty_simple("Heh"), - interface_name: None, - block: block.clone(), - })] + vec![decl(Impl { type_name: ty_simple("Heh"), interface_name: None, block: block.clone() })] ); //TODO `"impl Heh { fn yolo() { }; fn swagg() { }; }"` ought to work