© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•4y ago•
9 replies
Anarchist

❔ Are TryAsync methods acceptable?

I've just been refactoring some implementations of a method I have to go from
T Load()
T Load()
to
bool TryLoad(out T? result)
bool TryLoad(out T? result)
, which as far as I'm concerned is not an anti pattern. I was about to do the same for my
Task<T> LoadAsync
Task<T> LoadAsync
methods but am wondering if this is bad practice and having
bool TryLoadAsync(out Task<T?> result)
bool TryLoadAsync(out Task<T?> result)
may have some unforeseen consequences?
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

✅ methods
C#CC# / help
8mo ago
✅ Methods
C#CC# / help
16mo ago
✅ Methods
C#CC# / help
3y ago