This shebang line is more portable, as the user may not have python installed in /usr/local/bin/python. Also, according to PEP 486, the line makes the Python Launcher aware of virtual environments.
The code was using directory separator in the regex itself,
which means on Windows it was leaving unescaped backslash.
Added explicit escape for such cases.
456 - Tweak lint to sometimes allow { on line following array initialization.
455 - Recognize more types.
454 - Try a bit harder to detect templated types.
453 - Changed error message wording on build/storage_class to be less ambiguous.
452 - Recognize more types to silence false positives for brace warnings.
451 - <skipped>
450 - <skipped>
449 - Ignore whitespace/tab for Linux Kernel files.
448 - Remove some more false positive lint warnings for int64{n}.
447 - Just one warning message for line length is enough, don't need two.
446 - Allow braced conversions to int16, uint64, etc. per the style guide.
445 - Fixed handling of backslash escapes for checking whether a "//" is quoted.
444 - Reduced dependency on hardcoded .cc extension.
443 - Disable single-arg constructor checks by default, since ClangTidy has the
same check. We could just delete the check entirely, but it's slightly
useful in places that can't run ClangTidy.
442 - Fix matching of macro names in CheckTrailingSemicolon to include digits.
441 - Deleted checks:
- All checks for RValue references.
- Spacing check around boolean &&, because those look like RValue
references.
A huge amount of code and effort were dedicated to tell RValue
references apart from boolean expressions, and to differentiate
allowed versus banned RValue references. But we still get regular
false positives from this one check. Rather than making the check
more complex than what it already is, it seemed safer to just delete
it altogether for now, and have a different process for catching
RValue references.
440 - Add rule to cpplint to throw error on empty if statement bodies without
else clauses. If statement bodies with comments are not considered empty.
439 - Allow spaces before closing brace of namespace block so that namespaces
inside of macro definitions (where the entire macro definition is
indented) are not treated as errors.
438 - cpplint: fix a false positive on `new const int(x)`.
437 - Only check for function length when current line is inside a function.
436 - cpplint: Catch static `std::string` instances as well as those written as
`string`. Previously users would sometimes work around the lint warning by
changing their code to even worse code by adding the "std::" prefix.
435 - cpplint: Be a little smarter about warning on indentation.
434 - cpplint: Remove false positives on some functions returning string const&.
433 - cpplint: improve diagnostics of global/static string objects.
432 - Allow non-const reference parameters for iostream based types.
431 - Better handling of raw strings inside comments.
430 - <noop>
429 - <skipped>
428 - <skipped>
427 - Add support to CHECK_NOTNULL when checking if a member variable is
initialized with itself.
426 - Allow suppressing specific warnings in C headers.
425 - Allow spaces before parens for inline assembly.
424 - Remove lint checks for {EXPECT,ASSERT}_.*_M.
423 - Allow comment lines of more than 80 characters if they contain a single
"word" (without any spaces).
422 - cpplint: Warn on inclusion of C++14 headers.
421 - cpplint: recognize <shared_mutex> as a standard library header.
420 - Add <scoped_allocator> to cpplint's list of C++ standard headers.
419 - Add cpplint check for tr1/ headers. We removed the nanny guards for these
418 - <skipped>
417 - Update the styleguide and cpplint to allow unnamed parameters
416 - Remove the rule explicitly banning non-default move operations.
415 - Remove the check for explicit multi arg constructors
414 - Include clarity of lambda default captures in "pros" section, mention
of capturing `this` and lambdas which escape the current scope in "cons".
Soften the ban on default captures to a preference, with admonition against
using them for capturing `this` or when they will escape the current scope.
This is a fairly straightforward change with a brief inclusion
of 2 problematic cases for implicit capture. As this is the style
guide, I'm not sure how much more detail is appropriate.
413 - Fixed a bug by making regex in CleanseRawStrings match multiple raw strings
on a single line in left-to-right order.
412 - Fixed false positive for classes derived using decltype()
411 - <skipped>
410 - Recognize '1LL<<20' as numeric and don't flag it for spacing.
409 - Fixed false positive for access-specifier used with virtual in inheritance.
408 - Fixed false positive in determining rvalue parameter types for functions
whose return type is on the previous line.
407 - Allow different include sections to be separated by anything other than
#include.
406 - Disable readability/streams warnings in cpplint, to reflect style guide
changes.
405 - Fixed false positive for whitespace checks with CUDA code.
404 - Do not issue cpplint warnings for use of Doxygen-style comments.
403 - Allow RValue types that were listed in template-argument-list.
Fixed handling of RValue types after pointer parameters.
402 - Change the style guide to allow std::forward and associated use of rvalue
references.
401 - Fixed cpplint crash when checking header guards for filenames containing
meta characters.
400 - Fixed false positive for alignas() used with anonymous struct or union.
399 - Fixed false positive for template function calls with braced constructor.
398 - Allow #endif header guard comments to use "/**/" style if there are no
"//" comments in the same file.
397 - Fixed false positives for DISALLOW macro check position check.
396 - Don't treat lambda functions with return value syntax as casts.
395 - <skipped>
394 - Fixed RValue references for out-of-line inner class constructor
declarations.
393 - Fixed false positive for redundant override/final by ignoring declarators.
392 - Fixed false positive for taking address of a function pointer return value
being recognized as taking address of a cast.
391 - Version of cpplint that fixes the spacing around the '=' operator.
390 - <skipped>
389 - Don't warn on non-const reference arguments of out-of-line method
definitions.
388 - Fixed false positive for "virtual" from virtual base class be interpreted
as virtual member function.
R=erg@google.com
Review URL: https://codereview.appspot.com/184990043
This should make packaged versions of google-c-style (like from MELPA)
provide the symbols without doing explicit 'require.
Patch by Kimmo Kinnunen <kkinnunen@nvidia.com>.
387 - Allow lint warnings on the next line to be suppressed with NOLINTNEXTLINE.
386 - Fixed false positive for strcat and strcpy.
385 - Fixed false positive for bitwise and on last line of a multi-line
384 - Remove unused deprecated testing/base/googletest.h header.
383 - Fixed false positive for bitwise and on last line of a multi-line
initializer list that ends with closing brace on the same line.
382 - Allow header guard warning to be silenced with
"// NOLINT(build/header_guard)" comment.
381 - Removed check for spaces between "//" and "TODO".
380 - Fix typo: Redudnant -> Redundant
379 - Added check for redundant "virtual" and "override" function-specifier.
378 - Updated missing "explicit" message to match style guide wording
377 - Add cpplint check to prevent .cc file inclusions from other packages.
These are generally bad and we should prevent regressions like this until
proper BUILD layering checks are in place.
376 - Silence missing braces warning for conditional statements inside lambdas.
375 - Warn about multi-arg constructors being explicit only at highest severity
level.
374 - Warn about non-single-argument constructors marked explicit.
373 - Exclude 'case' from function spacing check.
372 - Exclude third party headers such as Python.h from these checks:
371 - Fixed false positive for function pointer parameters followed by other
parameters.
370 - Allow RValue reference for default inline constructor.
369 - Fixed false positive for array of references and operator,().
368 - Silence named parameter warning for macros.
367 - Fixed false positive for duplicate header warning across preprocessor
boundaries.
366 - Allow rvalue references for constructors and assignment operator.
365 - Stop handling DISALLOW_EVIL_CONSTRUCTORS in cpplint.py,
since it's going away.
364 - Fixed false positive for member function in nested classes.
363 - Namespace indentation for cpplint. The C++ style guide enforced that items
within a namespace do not receive an extra level of indentation.
362 - Fixed false positive for multi-line member functions returning strings.
361 - Do not suggest replacement CHECK macros if custom error messages are used.
360 - Silence nonconst reference warning for multiline derived functions.
359 - Silence non-const reference warnings for derived functions.
358 - Added link to developer guide.
357 - Remove the partial ban on std::move and related features. More general
356 - Fixed false positive for << inside macros.
355 - Make _NestingState class public.
354 - Fixed false positive for multiline function templates.
353 - Fixed false positive for lambda capture.
352 - Silence RValue reference warnings that are enclosed in a
351 - Do not warn on CR-LF lines if all input lines are uniformly CR-LF.
350 - Tweaked the error messages for static mutex with default constructors.
349 - Fixed false positive for unnamed parameters in macros.
348 - Recognize &&... as RValue references.
347 - Use alternative error message for including <ostream>.
346 - Fixed false positive for function style template argument.
345 - Fixed false positive for braced constructor call inside brackets.
344 - Minor spelling and grammar fix.
343 - Fixed false positive for non-const reference check inside constructor
342 - Fixed cases where rvalue references are not identified correctly:
341 - Check that third party header files have some header guard, but do not
340 - Don't check header guards in third party files.
339 - Instead of treating thread annotations as macro function calls, skip over
them in parsing function signatures. This silences false positives for
lambdas with thread annotations.
338 - Fixed false positive for deprecated cast where return type of function
337 - Fixed false positive for alias-declarations of function pointers.
336 - Improved error message for taking address of something dereferenced
335 - Added support for C++14 digit separators.
334 - Silence long line warnings for JNI.
333 - Fixed false positive for constructor calls for rand{} being
332 - Elide C++11 raw strings as an empty quoted string instead of
331 - Split up long functions in cpplint.py and cpplint_unittest.py
330 - Fixed false positive for missing space check around "using operator;"
329 - Fixed false positive for indent check around multi-line raw strings.
R=erg@google.com
Review URL: https://codereview.appspot.com/125980043
Added the ability to provide CPPLINT.cfg files to provide
linter message filters per sub-directory and special exclusion
rules. Each file can have instructions like:
filter=-build/include_order,+build/include_alpha
exclude_files=.*\.cc
The above disables build/include_order warning and enables
build/include_alpha as well as excludes all .cc from being
processed by linter, in the current directory (where the .cfg
file is located) and all sub-directories.
Patch by avakulenko@google.com.
Related CL: https://codereview.chromium.org/406373002/
Review URL: https://codereview.appspot.com/115340043