https://kotlinlang.org logo
#coroutines
Title
# coroutines
v

voddan

03/05/2018, 12:41 PM
If I create an interface with a method which potentially could be suspendible in some of the implementations in the future, do I get any penalty from marking this method
suspend
just in case?
e

elizarov

03/05/2018, 1:33 PM
All invocations will have to be from suspending context. There is a penalty in the form of state machine. You should measure for your particular case.
3 Views