--output=sed src/*.cpp
1
5
sed -i '120s/,\([^ ]\)/, \1/g' src/sillycode.cpp # Missing space after ,  [whitespace/comma] [3]
sed -i '122s/\s*$//' src/sillycode.cpp # Line ends in whitespace.  Consider deleting these extra spaces.  [whitespace/end_of_line] [4]
sed -i '126s/,\([^ ]\)/, \1/g' src/sillycode.cpp # Missing space after ,  [whitespace/comma] [3]
sed -i '208s/\([^ ]\){/\1 {/' src/sillycode.cpp # Missing space before {  [whitespace/braces] [5]

# src/sillycode.cpp:0:  "No copyright message found.  You should have a line: "Copyright [year] <Copyright Owner>""  [legal/copyright] [5]
# src/sillycode.cpp:3:  "Found C system header after C++ system header. Should be: sillycode.h, c system, c++ system, other."  [build/include_order] [4]
# src/sillycode.cpp:8:  "public: should be indented +1 space inside class Date"  [whitespace/indent] [3]
# src/sillycode.cpp:14:  "Is this a non-const reference? If so, make const or use a pointer: vector<string>& v"  [runtime/references] [2]
# src/sillycode.cpp:15:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:39:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:40:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:40:  "If/else bodies with multiple statements require braces"  [readability/braces] [4]
# src/sillycode.cpp:49:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:49:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:55:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:60:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:60:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:64:  "public: should be indented +1 space inside class X"  [whitespace/indent] [3]
# src/sillycode.cpp:65:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:65:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:66:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:66:  "Single-parameter constructors should be marked explicit."  [runtime/explicit] [5]
# src/sillycode.cpp:74:  "public: should be indented +1 space inside class X2"  [whitespace/indent] [3]
# src/sillycode.cpp:75:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:76:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:76:  "Single-parameter constructors should be marked explicit."  [runtime/explicit] [5]
# src/sillycode.cpp:80:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:80:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:84:  "public: should be indented +1 space inside class X3"  [whitespace/indent] [3]
# src/sillycode.cpp:85:  "Constructors callable with one argument should be marked explicit."  [runtime/explicit] [5]
# src/sillycode.cpp:86:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:86:  "Lines should be <= 80 characters long"  [whitespace/line_length] [2]
# src/sillycode.cpp:94:  "public: should be indented +1 space inside class Foo"  [whitespace/indent] [3]
# src/sillycode.cpp:100:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:110:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:111:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:111:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:113:  "public: should be indented +1 space inside class Vector2"  [whitespace/indent] [3]
# src/sillycode.cpp:118:  "Is this a non-const reference? If so, make const or use a pointer: N::X& a"  [runtime/references] [2]
# src/sillycode.cpp:118:  "Is this a non-const reference? If so, make const or use a pointer: N::X& b"  [runtime/references] [2]
# src/sillycode.cpp:119:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:120:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:122:  "Weird number of spaces at line-start.  Are you using a 2-space indent?"  [whitespace/indent] [3]
# src/sillycode.cpp:123:  "Is this a non-const reference? If so, make const or use a pointer: N::X& a"  [runtime/references] [2]
# src/sillycode.cpp:123:  "Is this a non-const reference? If so, make const or use a pointer: N::X& b"  [runtime/references] [2]
# src/sillycode.cpp:124:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:125:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:125:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:126:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:143:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:144:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:149:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:150:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:155:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:156:  "Missing spaces around ="  [whitespace/operators] [4]
# src/sillycode.cpp:162:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:164:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:166:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:168:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:171:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:171:  "Do not use variable-length arrays.  Use an appropriately named ('k' followed by CamelCase) compile-time constant for the size."  [runtime/arrays] [1]
# src/sillycode.cpp:175:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:178:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:178:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:178:  "Static/global string variables are not permitted."  [runtime/string] [4]
# src/sillycode.cpp:179:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:179:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:184:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:184:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:190:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:190:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:195:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:195:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:197:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:197:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:199:  "If an else has a brace on one side, it should have it on both"  [readability/braces] [5]
# src/sillycode.cpp:202:  "An else should appear on the same line as the preceding }"  [whitespace/newline] [4]
# src/sillycode.cpp:202:  "If an else has a brace on one side, it should have it on both"  [readability/braces] [5]
# src/sillycode.cpp:208:  "Static/global string variables are not permitted."  [runtime/string] [4]
# src/sillycode.cpp:209:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:209:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:214:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:217:  "{ should almost always be at the end of the previous line"  [whitespace/braces] [4]
# src/sillycode.cpp:218:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:218:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:219:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:219:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:220:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:220:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:225:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:225:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:227:  "Static/global string variables are not permitted."  [runtime/string] [4]
# src/sillycode.cpp:228:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:228:  "Using C-style cast.  Use reinterpret_cast<double*>(...) instead"  [readability/casting] [4]
# src/sillycode.cpp:236:  "public: should be indented +1 space inside class derived2"  [whitespace/indent] [3]
# src/sillycode.cpp:241:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:243:  "Lines should be <= 80 characters long"  [whitespace/line_length] [2]
# src/sillycode.cpp:243:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:243:  "Using C-style cast.  Use reinterpret_cast<derived2*>(...) instead"  [readability/casting] [4]
# src/sillycode.cpp:244:  "Lines should be <= 80 characters long"  [whitespace/line_length] [2]
# src/sillycode.cpp:244:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:253:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:254:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:257:  "Tab found; better to use spaces"  [whitespace/tab] [1]
# src/sillycode.cpp:257:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]
# src/sillycode.cpp:260:  "Empty loop bodies should use {} or continue"  [whitespace/empty_loop_body] [5]
# src/sillycode.cpp:260:  "At least two spaces is best between code and comments"  [whitespace/comments] [2]

