You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
EnumerableAsyncExtensions from namespace Cysharp.Threading.Tasks hides the System.Linq extensions
Case:
You are trying to get all the strings from the of List<string> with Select() method.
What you are excepting to get: IEnumerable<string>
What you are actually get: "Cannot convert expression type 'string' to return type 'Cysharp.Threading.Tasks.UniTask"
This happens because you have a using of Cysharp.Threading.Tasks namespace, that contains this extensions. Until you manually add the System.Linq usage into the file it will show you a error or potentially can cause an unexpected behaviour
Our suggestion is to not use Cysharp.Threading.Tasks namespace for extensions, but add the proper naming like Cysharp.Threading.Tasks.IEnumerable.Extensions (for example) to make usage of such extensions obvious for developers
Thank you!
The text was updated successfully, but these errors were encountered:
For ***Async, we expect Task to be the return value.
The rule we use in Async LINQ is to use ***Await if we receive an async function as an argument (we also adopted the same thing in R3)
Hello! We are faced with issue, that
EnumerableAsyncExtensions from namespace Cysharp.Threading.Tasks hides the System.Linq extensions
Case:
You are trying to get all the strings from the of List<string> with Select() method.
What you are excepting to get: IEnumerable<string>
What you are actually get: "Cannot convert expression type 'string' to return type 'Cysharp.Threading.Tasks.UniTask"
This happens because you have a using of Cysharp.Threading.Tasks namespace, that contains this extensions. Until you manually add the System.Linq usage into the file it will show you a error or potentially can cause an unexpected behaviour
Our suggestion is to not use Cysharp.Threading.Tasks namespace for extensions, but add the proper naming like Cysharp.Threading.Tasks.IEnumerable.Extensions (for example) to make usage of such extensions obvious for developers
Thank you!
The text was updated successfully, but these errors were encountered: