cpplint gives me the following errors for one of my test files:
test/unit/math/prim/mat/vectorize/expect_prim_binary_std_vector_value.hpp(1): Lines should be <= 80 characters long [whitespace/line_length] [2]
test/unit/math/prim/mat/vectorize/expect_prim_binary_std_vector_value.hpp(2): Lines should be <= 80 characters long [whitespace/line_length] [2]
I’m not sure how I can shorten my header guard to be under 80 characters. Is it possible to change cpplint to ignore checking the length of header guards?
Thanks, Daniel. Then, should cpplint be changed to avoid checking header guards? Even if it’s a test, I like using the full file path and file name as a header guard to avoid duplicate header guard.
No, I don’t think we should be changing our best practices that apply everywhere on the first exception. If it happens a few more times, we should start considering it.
But… technically, I don’t know if we can skip header guards.
And there’s already a mechanism in place to suppress the warning in cpplint.
Also, @seantalts is thinking about removing a folder level for all the math library. That might make this a little better.
The conflict is full path encoding vs. 80 characters. Ideally, we’d check the path was encoded in the header guard and then we’d ignore the line length. I can imagine that’s not so easy to encode, so I don’t care what the workaround is.