Skip to content

Commit

Permalink
Executor
Browse files Browse the repository at this point in the history
- Fixed `isSupportedReturn` check
- Also fixed the future builder
  • Loading branch information
deavmi committed Oct 1, 2023
1 parent 6d81be4 commit fb4cc5b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/guillotine/executor.d
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ private bool isSupportedReturn(alias FuncSymbol)()
{
return __traits(isSame, ReturnType!(FuncSymbol), int) ||
__traits(isSame, ReturnType!(FuncSymbol), bool) ||
isAssignable!(Object, FuncSymbol) ||
isAssignable!(Object, ReturnType!(FuncSymbol)) ||
__traits(isSame, ReturnType!(FuncSymbol), float) ||
__traits(isSame, ReturnType!(FuncSymbol), void);
}
Expand Down Expand Up @@ -143,7 +143,7 @@ private template WorkerFunction(alias FuncIn)
{
valUnion.str = FuncIn();
}
else static if(__traits(isSame, funcInReturn, Object))
else static if(isAssignable!(Object, funcInReturn))
{
valUnion.object = FuncIn();
}
Expand Down

0 comments on commit fb4cc5b

Please # to comment.