From 1e6f428cbfd823e6a9a603f67c90fe97039f0189 Mon Sep 17 00:00:00 2001 From: Grant Shangreaux Date: Mon, 18 Oct 2021 23:42:00 -0500 Subject: Clean: fix all compiler warnings - comment out unused gdnative module use - handle Results returned by the test audio function --- klangfarbrs/src/lib.rs | 8 +++++--- klangfarbrs/src/main.rs | 5 ++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/klangfarbrs/src/lib.rs b/klangfarbrs/src/lib.rs index eb7f027..cdeb52b 100644 --- a/klangfarbrs/src/lib.rs +++ b/klangfarbrs/src/lib.rs @@ -1,4 +1,4 @@ -use gdnative::api::Resource; +// use gdnative::api::Resource; use gdnative::prelude::*; #[derive(NativeClass)] @@ -24,8 +24,10 @@ impl Synth { #[export] fn _ready(&self, _owner: &Node) { - godot_print!("POOOP"); - test::test(); + match test::test() { + Ok(()) => godot_print!("POOOP"), + Err(error) => godot_print!("SHITE! {:?}", error), + }; } } diff --git a/klangfarbrs/src/main.rs b/klangfarbrs/src/main.rs index 066cd9d..fa1cdfb 100644 --- a/klangfarbrs/src/main.rs +++ b/klangfarbrs/src/main.rs @@ -1,5 +1,8 @@ use klangfarbrs::test::test; fn main() { - test(); + match test() { + Ok(()) => (), + Err(error) => panic!("oopsie: {:?}", error), + }; } -- cgit v1.2.3