Debug statements are always useful during development. But include them in production code - particularly in code that runs client-side - and you run the risk of inadvertently exposing sensitive information.

Noncompliant Code Example

private void DoSomething()
{
    // ...
    Console.WriteLine("so far, so good..."); // Noncompliant
    // ...
}

Exceptions

The following are ignored by this rule:

See

Deprecated

This rule is deprecated; use {rule:csharpsquid:S106} instead.