What is better coding practice for single-line code blocks following an if statement - braces or no braces? Just to avoid too many "Well, it depends on what language you're using..." answers, let's say for C#. In other words, which is better:
if(somecondition)
{
singleLineStatement;
}
Or
if(somecondition)
singleLineStatement;
I think the consensus is to use braces. If you omit the braces there is a risk that someone will add an extra line without noticing the missing braces.