Eval should never return an error
Only awaiting eval should error. Eval should always be available, even if using its methods returns errors.
This commit is contained in:
9 files changed
+65
-44
No files matched your search
@@ -13,9 +13,9 @@ pub fn init_eval() {
|
||||
/// Reprents the ssr-target's provider of evaluators.
|
||||
pub struct SSREvalProvider;
|
||||
impl EvalProvider for SSREvalProvider {
|
||||
fn new_evaluator(&self, _: String) -> Result<GenerationalBox<Box<dyn Evaluator>>, EvalError> {
|
||||
fn new_evaluator(&self, _: String) -> GenerationalBox<Box<dyn Evaluator>> {
|
||||
let owner = UnsyncStorage::owner();
|
||||
Ok(owner.insert(Box::new(SSREvaluator) as Box<dyn Evaluator + 'static>))
|
||||
owner.insert(Box::new(SSREvaluator) as Box<dyn Evaluator + 'static>)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user