Este producto no es compatible con el sitio Datadog seleccionado. ().
Esta página aún no está disponible en español. Estamos trabajando en su traducción.
Si tienes alguna pregunta o comentario sobre nuestro actual proyecto de traducción, no dudes en ponerte en contacto con nosotros.

Metadata

ID: kotlin-code-style/nullable-type-spacing

Language: Kotlin

Severity: Notice

Category: Code Style

Description

A type can be declared as nullable by appending a question mark (?) to the type name. The proper coding convention is to have no space between the type name and the question mark. This rule ensures that there is no space between the type and the question mark.

Non-Compliant Code Examples

val foo: String ? = null
val foo: List<String ?> = listOf(null)
val foo: Map<String, String> ? = listOf(null);

Compliant Code Examples

val foo: String? = null
val foo: List<String?> = listOf(null)
val foo: Map<String, String>? = listOf(null);
https://static.datadoghq.com/static/images/logos/github_avatar.svg https://static.datadoghq.com/static/images/logos/vscode_avatar.svg jetbrains

Integraciones sin problemas. Prueba Datadog Code Security