diff options
| author | Emil Fresk <emil.fresk@gmail.com> | 2023-01-07 14:26:55 +0100 |
|---|---|---|
| committer | Henrik Tjäder <henrik@tjaders.com> | 2023-03-01 00:31:08 +0100 |
| commit | 76595b7aedd2a14aea8569b75fabe62120f93230 (patch) | |
| tree | 5b94ff5b348a57347066e97f1bac8dda1d716b80 /macros/src/codegen/local_resources.rs | |
| parent | b054e871d486e8eb35e3c98a73652640238c5e7d (diff) | |
All codegen is now explicit
Diffstat (limited to 'macros/src/codegen/local_resources.rs')
| -rw-r--r-- | macros/src/codegen/local_resources.rs | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/macros/src/codegen/local_resources.rs b/macros/src/codegen/local_resources.rs index 6fc63cd..e6d1553 100644 --- a/macros/src/codegen/local_resources.rs +++ b/macros/src/codegen/local_resources.rs @@ -6,17 +6,8 @@ use quote::quote; /// Generates `local` variables and local resource proxies /// /// I.e. the `static` variables and theirs proxies. -pub fn codegen( - app: &App, - _analysis: &Analysis, -) -> ( - // mod_app -- the `static` variables behind the proxies - Vec<TokenStream2>, - // mod_resources -- the `resources` module - TokenStream2, -) { +pub fn codegen(app: &App, _analysis: &Analysis) -> TokenStream2 { let mut mod_app = vec![]; - // let mut mod_resources: _ = vec![]; // All local resources declared in the `#[local]' struct for (name, res) in &app.local_resources { @@ -70,5 +61,5 @@ pub fn codegen( )); } - (mod_app, TokenStream2::new()) + quote!(#(#mod_app)*) } |
