Minor performance tweaks
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone Build is failing

This commit is contained in:
2022-12-25 12:55:09 +01:00
parent 055fbfba78
commit 43bc811704
4 changed files with 23 additions and 28 deletions

View File

@@ -6,8 +6,8 @@ use std::ptr::drop_in_place;
/// Instantiates a new Learnable Moves.
#[no_mangle]
extern "C" fn learnable_moves_new() -> OwnedPtr<Box<dyn LearnableMoves>> {
Box::into_raw(Box::new(Box::new(LearnableMovesImpl::new())))
extern "C" fn learnable_moves_new(max_level: LevelInt) -> OwnedPtr<Box<dyn LearnableMoves>> {
Box::into_raw(Box::new(Box::new(LearnableMovesImpl::new(max_level))))
}
/// drops a learnablemoves struct.