this crashed for us with pretty much any string passed in.
but in context we were using this as a generic way to avoid the optional warning for a string in print…
print(“yada (blah) yada”)
will now (swift3) give you a compiler warning if blah is optional
so I replaced them all with
print(“yada (thisBuildsButCrashesAtRuntime(blah)) yada”)
which compiles OK, and was supposed to either return the non null string, or “NULL”… and print it out…
but which actually crashed on Android when we ran it.
changing to the thisWorks case where we don’t use the guard var, but use the parameter again…
I don’t recall if they all crashed… or just the ones where blah was in fact optional
so I would check
var s1: String?
var s2: String? = "xyz"
var s3 = “abc”