Cleanup
This commit is contained in:
parent
be7fa2e48b
commit
b4859e817e
1 changed files with 0 additions and 2 deletions
|
|
@ -4,14 +4,12 @@ use std::sync::{Arc, Mutex};
|
||||||
use rhai::{Dynamic, NativeCallContextStore};
|
use rhai::{Dynamic, NativeCallContextStore};
|
||||||
use rhai::{EvalAltResult, FnPtr};
|
use rhai::{EvalAltResult, FnPtr};
|
||||||
|
|
||||||
// TODO: This should not be public
|
|
||||||
/// A struct that represents a function that will get called when the Promise is resolved.
|
/// A struct that represents a function that will get called when the Promise is resolved.
|
||||||
pub(crate) struct PromiseCallback {
|
pub(crate) struct PromiseCallback {
|
||||||
callback: Dynamic,
|
callback: Dynamic,
|
||||||
following_promise: Arc<Mutex<PromiseInner>>,
|
following_promise: Arc<Mutex<PromiseInner>>,
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: This should not be public
|
|
||||||
/// Internal representation of a Promise.
|
/// Internal representation of a Promise.
|
||||||
pub(crate) struct PromiseInner {
|
pub(crate) struct PromiseInner {
|
||||||
pub(crate) callbacks: Vec<PromiseCallback>,
|
pub(crate) callbacks: Vec<PromiseCallback>,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue