kotlin - What is the @InlineOnly annotation? -


i often see the @inlineonly annotation when browsing kotlin's stdlib. far recall annotation happens on inline functions. purpose of annotation? isn't obvious inline functions inlined? it's documentation isn't helpful

specifies function should not called directly without inlining

is possible inline functions called not inline?

to quote answer found here:

inlineonly means java method corresponding kotlin function marked private java code can not access (which way call inline function without inlining it).

this annotation internal because

this annotation added in last moment before release, hadn't time validate design , decided keep internal while. there chances make public later.


Comments

Popular posts from this blog

angular - DownloadURL return null in below code -

meteor - inserting data to database gives error "insert failed: Method '/texts/insert' not found" -