essessv / google-styleguide

Automatically exported from code.google.com/p/google-styleguide
0 stars 0 forks source link

Example Function 'CalculateSampleCovariance' in the R Style Guide mixes use and omission of curly braces for single-statement blocks. #1

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
The function definition is at 
http://google-styleguide.googlecode.com/svn/trunk/google-r-style.html

What is the expected output? What do you see instead?
As stated earlier in the style guide, curly braces should be used or not used 
consistently when dealing with single-statement blocks.  In the example 
function 'CalculateSampleCovariance', curly braces are used in the 
single-statement blocks following the first two if statements and not the 
single-statement block following the third.

Original issue reported on code.google.com by bkj.emai...@gmail.com on 14 Aug 2010 at 3:47

GoogleCodeExporter commented 9 years ago

Original comment by mmento...@gmail.com on 4 Oct 2010 at 4:30