var enderecoNulo:Endereco? = Endereco("Rua Vergueiro",12,"Juripa");
println(enderecoNulo?.logradouro?.length?.toUByte())
enderecoNulo = null
enderecoNulo?.let { endereco:Endereco ->
println(endereco.logradouro.length)
}
enderecoNulo?.let {
val tamComp:Int = it.logradouro?.length ?: throw IllegalStateException()
println(tamComp)
}
Dando isso: Kotlin: Unresolved reference: logradouro