Visitar URL original
Disable warning in clang-tidy · Issue #2477 · neomake/neomake · GitHub
Skip to content

Disable warning in clang-tidy #2477

Open

Description

@maharvey

Expected behavior

Disable an annoying clang-tidy warning on linux

Steps to reproduce

  1. Create a source file containing strncpy()
  2. Observe that neomake complains
  3. There is no way to disable this warning globally

In this case I would need to pass --checks=-clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling to clang-tidy

Adding this as args for the c maker gets rid of the warning:

function! neomake#makers#ft#c#clangtidy() abort
    return {
        \ 'exe': 'clang-tidy',
        \ 'args': ['--checks=-clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling'],
        \ 'errorformat':
etc...

It would be nice if there was a way to set this in .vimrc

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions