Silver vs Swift (3) incompatibility

Hi,

Just found this incompatibility… here’s Silver in Fire IDE:

vs here’s Swift (3) in XCode (8):

Silver will only work if I put the second parameter which is separator. Is that mean Silver not supporting full named parameter (with arbitrary parameter order)? I’ve searched on Silver’s online documentation and got no explanation about this.

Thank you.

-Bee

Looking like maybe the overload is missing default value in SBL. i’ll check.

Hm, no, the defaults are there:

public func print(object: Object?, separator: String = " ", terminator: String? = nil) {

Thanks, logged as bugs://77968

bugs://77968 got closed with status fixed.

Just tried the brand new Fire and Elements 9.2… and this problem persists. :slight_smile:

Oh, one more thing… I also miss the to: parameter of print() function. As described here which is part of Swift Standard Library.

Thank you.

bugs://77968 got reopened.

Yeah, supporting the stream part of SBL is not a high priority right now, sorry. Eventually we may get to it. Pull requests to SBL were welcome, of course.

Oh, actually, we already have that, except Apple (of course) renamed it again, sigh. we have

func print<Target : OutputStreamType>(_ objects: Object?..., separator: String = " ", terminator: String? = nil, inout toStream output: Target) {

will fix.

bugs://77968 got closed with status fixed.