aboutsummaryrefslogtreecommitdiffstats
path: root/src/_cppcheck
diff options
context:
space:
mode:
authorShohei YOSHIDA <syohex@gmail.com>2023-10-03 20:22:20 +0900
committerShohei YOSHIDA <syohex@gmail.com>2023-10-03 20:22:20 +0900
commit1fab9820473ac1d94606783d590068790fc57026 (patch)
tree79284516a24d5305c246c6a657c603f616f7cba9 /src/_cppcheck
parentMerge pull request #1046 from zsh-users/do-not-use-global-variable (diff)
downloadzsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar.gz
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar.bz2
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar.lz
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar.xz
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.tar.zst
zsh-completions-1fab9820473ac1d94606783d590068790fc57026.zip
Update cppcheck completion for version 2.12
Diffstat (limited to 'src/_cppcheck')
-rw-r--r--src/_cppcheck7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/_cppcheck b/src/_cppcheck
index 019a1a7..e8ab3fe 100644
--- a/src/_cppcheck
+++ b/src/_cppcheck
@@ -40,7 +40,7 @@
# Notes
# -----
#
-# Created for Cppcheck version 2.9
+# Created for Cppcheck version 2.12 (https://github.com/danmar/cppcheck)
#
# ------------------------------------------------------------------------------
@@ -52,6 +52,8 @@ _cppcheck() {
local curcontext="$curcontext" state line
typeset -A opt_args
+ local check_ids='(all warning style performance portability information unusedFunction missingInclude)'
+
_arguments -C \
"--addon=[Execute addon]" \
"--addon-python=[Specify the python interpreter]: :_files" \
@@ -62,11 +64,12 @@ _cppcheck() {
"--config-exclude=[Path to be excluded from configuration checking]:directory:_files -/" \
"--config-exclude-files=[A file that contains a list of config-excludes]:file:_files" \
"--doc[Print a list of all available checks]" \
+ "*--disable=[Disable indivisual checks]:id:$check_ids" \
"--dump[Dump xml data for each translation unit]" \
"-D[Define preprocessor symbol]" \
"-U[Undefine preprocessor symbol]" \
"-E[Print preprocessor output on stdout and don't do any further processing]" \
- "--enable[Enable additional checks]:id:(all warning style performance portability information unusedFunction missingInclude)" \
+ "--enable=[Enable additional checks]:id:$check_ids" \
"--error-exitcode=[Integer to return if errors are found]" \
"--errorlist[Print a list of all the error messages in XML format]" \
"--exitcode-suppressions=[Used when certain messages should be displayed but should not cause a non-zero exitcode]:_files" \