This commit is contained in:
Mark 2023-10-28 14:07:10 +02:00
parent 59e36d1535
commit 2c9fb1b4a4
2 changed files with 5 additions and 5 deletions

View File

@ -46,10 +46,10 @@ impl Config {
.collect::<Option<Vec<_>>>(),
) {
for f in f {
let ret = f.0(&iter)?;
if !ret.is_zero_tuple() {
return Err(format!("for_each function must return (), not {ret}").into());
}
let _ret = f.0(&iter)?;
// if !ret.is_zero_tuple() {
// return Err(format!("for_each function must return (), not {ret}").into());
// }
}
} else {
return Err(format!(

View File

@ -83,7 +83,7 @@ impl Config {
let mut out = Type::empty();
for t in a.types.iter() {
if let Some(t) = t.as_any().downcast_ref::<ThreadT>() {
out.add(Arc::new(Clone::clone(t)));
out.add(Arc::new(Clone::clone(&t.0)));
} else {
return Err(CheckError::new().msg(format!("Cannot call thread_await on a value of type {t}, which isn't a thread but part of the argument {a}.")));
}