adlint 1.18.6 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +287 -188
- data/MANIFEST +278 -92
- data/NEWS +16 -4
- data/bin/adlintize +124 -3
- data/etc/conf.d/fallback/traits.erb +54 -1
- data/etc/conf.d/i686-cygwin/traits-gcc_4.3.4.erb +54 -1
- data/etc/conf.d/i686-devkit/traits-gcc_4.5.2.erb +54 -1
- data/etc/conf.d/i686-linux/traits-gcc_4.5.1.erb +54 -1
- data/etc/conf.d/i686-mingw/traits-gcc_4.6.1.erb +54 -1
- data/etc/mesg.d/c_builtin/en_US/messages.yml +2998 -0
- data/etc/mesg.d/c_builtin/ja_JP/messages.yml +2998 -0
- data/etc/mesg.d/core/en_US/messages.yml +134 -0
- data/etc/mesg.d/core/ja_JP/messages.yml +134 -0
- data/features/{message_detection → code_check}/E0013.feature +2 -2
- data/features/{message_detection → code_check}/W0001.feature +4 -4
- data/features/{message_detection → code_check}/W0002.feature +6 -6
- data/features/{message_detection → code_check}/W0003.feature +8 -8
- data/features/{message_detection → code_check}/W0007.feature +16 -16
- data/features/{message_detection → code_check}/W0010.feature +8 -8
- data/features/{message_detection → code_check}/W0013.feature +16 -16
- data/features/code_check/W0016.feature +200 -0
- data/features/code_check/W0017.feature +270 -0
- data/features/code_check/W0025.feature +66 -0
- data/features/code_check/W0026.feature +143 -0
- data/features/{message_detection → code_check}/W0093.feature +6 -6
- data/features/{message_detection → code_check}/W0104.feature +14 -14
- data/features/{message_detection → code_check}/W0109.feature +6 -6
- data/features/code_check/W0119.feature +151 -0
- data/features/code_check/W0120.feature +137 -0
- data/features/code_check/W0121.feature +147 -0
- data/features/code_check/W0122.feature +142 -0
- data/features/code_check/W0123.feature +147 -0
- data/features/code_check/W0124.feature +142 -0
- data/features/code_check/W0125.feature +147 -0
- data/features/code_check/W0126.feature +142 -0
- data/features/code_check/W0127.feature +147 -0
- data/features/code_check/W0128.feature +147 -0
- data/features/code_check/W0129.feature +147 -0
- data/features/code_check/W0130.feature +159 -0
- data/features/code_check/W0131.feature +154 -0
- data/features/code_check/W0132.feature +137 -0
- data/features/code_check/W0133.feature +151 -0
- data/features/code_check/W0134.feature +151 -0
- data/features/code_check/W0135.feature +147 -0
- data/features/code_check/W0136.feature +151 -0
- data/features/code_check/W0137.feature +147 -0
- data/features/code_check/W0138.feature +151 -0
- data/features/code_check/W0139.feature +147 -0
- data/features/code_check/W0140.feature +159 -0
- data/features/code_check/W0141.feature +155 -0
- data/features/code_check/W0142.feature +152 -0
- data/features/code_check/W0143.feature +147 -0
- data/features/code_check/W0144.feature +146 -0
- data/features/code_check/W0145.feature +147 -0
- data/features/code_check/W0146.feature +146 -0
- data/features/code_check/W0147.feature +146 -0
- data/features/code_check/W0148.feature +147 -0
- data/features/code_check/W0149.feature +146 -0
- data/features/code_check/W0150.feature +146 -0
- data/features/code_check/W0151.feature +146 -0
- data/features/code_check/W0152.feature +155 -0
- data/features/code_check/W0153.feature +155 -0
- data/features/code_check/W0154.feature +154 -0
- data/features/code_check/W0155.feature +154 -0
- data/features/code_check/W0156.feature +167 -0
- data/features/code_check/W0157.feature +152 -0
- data/features/code_check/W0158.feature +147 -0
- data/features/code_check/W0159.feature +147 -0
- data/features/code_check/W0160.feature +147 -0
- data/features/code_check/W0161.feature +151 -0
- data/features/code_check/W0162.feature +146 -0
- data/features/code_check/W0163.feature +146 -0
- data/features/code_check/W0164.feature +146 -0
- data/features/code_check/W0165.feature +151 -0
- data/features/code_check/W0166.feature +146 -0
- data/features/code_check/W0167.feature +146 -0
- data/features/code_check/W0168.feature +146 -0
- data/features/code_check/W0169.feature +151 -0
- data/features/code_check/W0170.feature +146 -0
- data/features/code_check/W0171.feature +146 -0
- data/features/code_check/W0172.feature +146 -0
- data/features/code_check/W0173.feature +159 -0
- data/features/code_check/W0174.feature +159 -0
- data/features/code_check/W0175.feature +158 -0
- data/features/code_check/W0176.feature +158 -0
- data/features/code_check/W0177.feature +159 -0
- data/features/code_check/W0178.feature +155 -0
- data/features/code_check/W0179.feature +154 -0
- data/features/code_check/W0180.feature +154 -0
- data/features/code_check/W0181.feature +167 -0
- data/features/code_check/W0182.feature +147 -0
- data/features/code_check/W0183.feature +147 -0
- data/features/code_check/W0184.feature +148 -0
- data/features/code_check/W0185.feature +142 -0
- data/features/code_check/W0186.feature +142 -0
- data/features/code_check/W0187.feature +142 -0
- data/features/code_check/W0188.feature +142 -0
- data/features/code_check/W0189.feature +142 -0
- data/features/code_check/W0190.feature +142 -0
- data/features/code_check/W0191.feature +142 -0
- data/features/code_check/W0192.feature +142 -0
- data/features/code_check/W0193.feature +143 -0
- data/features/code_check/W0194.feature +142 -0
- data/features/code_check/W0195.feature +142 -0
- data/features/code_check/W0196.feature +142 -0
- data/features/code_check/W0197.feature +142 -0
- data/features/code_check/W0198.feature +142 -0
- data/features/code_check/W0199.feature +143 -0
- data/features/code_check/W0200.feature +142 -0
- data/features/code_check/W0201.feature +142 -0
- data/features/code_check/W0202.feature +142 -0
- data/features/code_check/W0203.feature +142 -0
- data/features/code_check/W0204.feature +142 -0
- data/features/code_check/W0205.feature +143 -0
- data/features/code_check/W0206.feature +150 -0
- data/features/code_check/W0207.feature +150 -0
- data/features/code_check/W0208.feature +150 -0
- data/features/code_check/W0209.feature +151 -0
- data/features/code_check/W0210.feature +151 -0
- data/features/code_check/W0211.feature +151 -0
- data/features/code_check/W0212.feature +147 -0
- data/features/code_check/W0213.feature +142 -0
- data/features/code_check/W0214.feature +147 -0
- data/features/code_check/W0215.feature +142 -0
- data/features/code_check/W0216.feature +142 -0
- data/features/code_check/W0217.feature +142 -0
- data/features/code_check/W0218.feature +142 -0
- data/features/code_check/W0219.feature +142 -0
- data/features/code_check/W0220.feature +142 -0
- data/features/code_check/W0221.feature +147 -0
- data/features/code_check/W0222.feature +142 -0
- data/features/code_check/W0223.feature +147 -0
- data/features/code_check/W0224.feature +142 -0
- data/features/code_check/W0225.feature +142 -0
- data/features/code_check/W0226.feature +142 -0
- data/features/code_check/W0227.feature +142 -0
- data/features/code_check/W0228.feature +142 -0
- data/features/code_check/W0229.feature +142 -0
- data/features/code_check/W0230.feature +147 -0
- data/features/code_check/W0231.feature +142 -0
- data/features/code_check/W0232.feature +148 -0
- data/features/code_check/W0233.feature +142 -0
- data/features/code_check/W0234.feature +143 -0
- data/features/code_check/W0235.feature +142 -0
- data/features/code_check/W0236.feature +143 -0
- data/features/code_check/W0237.feature +142 -0
- data/features/code_check/W0238.feature +143 -0
- data/features/code_check/W0239.feature +154 -0
- data/features/code_check/W0240.feature +155 -0
- data/features/code_check/W0241.feature +154 -0
- data/features/code_check/W0242.feature +155 -0
- data/features/code_check/W0243.feature +154 -0
- data/features/code_check/W0244.feature +155 -0
- data/features/code_check/W0245.feature +147 -0
- data/features/code_check/W0246.feature +147 -0
- data/features/code_check/W0247.feature +147 -0
- data/features/code_check/W0248.feature +142 -0
- data/features/code_check/W0249.feature +142 -0
- data/features/code_check/W0250.feature +146 -0
- data/features/code_check/W0251.feature +159 -0
- data/features/code_check/W0252.feature +155 -0
- data/features/code_check/W0253.feature +154 -0
- data/features/code_check/W0254.feature +154 -0
- data/features/code_check/W0477.feature +77 -0
- data/features/code_check/W0478.feature +103 -0
- data/features/code_check/W0479.feature +65 -0
- data/features/code_check/W0480.feature +119 -0
- data/features/code_check/W0481.feature +28 -0
- data/features/code_check/W0482.feature +64 -0
- data/features/code_check/W0483.feature +62 -0
- data/features/code_check/W0573.feature +91 -0
- data/features/{message_detection → code_check}/W0583.feature +2 -2
- data/features/{message_detection → code_check}/W0606.feature +2 -2
- data/features/{message_detection → code_check}/W0641.feature +16 -16
- data/features/{message_detection → code_check}/W0643.feature +12 -12
- data/features/{message_detection → code_check}/W0644.feature +50 -50
- data/features/{message_detection → code_check}/W0645.feature +16 -16
- data/features/{message_detection → code_check}/W0646.feature +16 -16
- data/features/{message_detection → code_check}/W0649.feature +28 -28
- data/features/{message_detection → code_check}/W0650.feature +24 -24
- data/features/code_check/W0685.feature +120 -0
- data/features/code_check/W0686.feature +92 -0
- data/features/{message_detection → code_check}/W0687.feature +4 -4
- data/features/{message_detection → code_check}/W0688.feature +12 -12
- data/features/{message_detection → code_check}/W0689.feature +8 -8
- data/features/{message_detection → code_check}/W0690.feature +6 -6
- data/features/{message_detection → code_check}/W0691.feature +14 -14
- data/features/{message_detection → code_check}/W0692.feature +4 -4
- data/features/{message_detection → code_check}/W0694.feature +10 -10
- data/features/code_check/W0695.feature +78 -0
- data/features/{message_detection → code_check}/W0697.feature +18 -18
- data/features/{message_detection → code_check}/W0698.feature +2 -2
- data/features/{message_detection → code_check}/W0699.feature +2 -2
- data/features/{message_detection → code_check}/W0700.feature +6 -6
- data/features/{message_detection → code_check}/W0703.feature +6 -6
- data/features/{message_detection → code_check}/W0705.feature +24 -24
- data/features/{message_detection → code_check}/W0707.feature +20 -20
- data/features/{message_detection → code_check}/W0711.feature +10 -10
- data/features/{message_detection → code_check}/W0712.feature +10 -10
- data/features/{message_detection → code_check}/W0713.feature +10 -10
- data/features/{message_detection → code_check}/W0714.feature +10 -10
- data/features/{message_detection → code_check}/W0715.feature +11 -11
- data/features/{message_detection → code_check}/W0716.feature +6 -6
- data/features/{message_detection → code_check}/W0717.feature +6 -6
- data/features/{message_detection → code_check}/W0718.feature +6 -6
- data/features/{message_detection → code_check}/W0719.feature +16 -16
- data/features/{message_detection → code_check}/W0723.feature +6 -6
- data/features/code_check/W0726.feature +95 -0
- data/features/{message_detection → code_check}/W0732.feature +6 -6
- data/features/{message_detection → code_check}/W0733.feature +6 -6
- data/features/{message_detection → code_check}/W0734.feature +16 -16
- data/features/{message_detection → code_check}/W0735.feature +16 -16
- data/features/{message_detection → code_check}/W0745.feature +10 -10
- data/features/code_check/W0747.feature +146 -0
- data/features/code_check/W0748.feature +148 -0
- data/features/code_check/W0749.feature +146 -0
- data/features/code_check/W0750.feature +146 -0
- data/features/code_check/W0751.feature +148 -0
- data/features/code_check/W0752.feature +143 -0
- data/features/code_check/W0753.feature +146 -0
- data/features/code_check/W0754.feature +146 -0
- data/features/code_check/W0755.feature +142 -0
- data/features/code_check/W0756.feature +148 -0
- data/features/code_check/W0757.feature +143 -0
- data/features/code_check/W0758.feature +143 -0
- data/features/code_check/W0759.feature +154 -0
- data/features/code_check/W0760.feature +154 -0
- data/features/code_check/W0761.feature +154 -0
- data/features/code_check/W0762.feature +154 -0
- data/features/code_check/W0763.feature +156 -0
- data/features/code_check/W0764.feature +151 -0
- data/features/code_check/W0765.feature +151 -0
- data/features/code_check/W0766.feature +151 -0
- data/features/code_check/W0767.feature +142 -0
- data/features/code_check/W0768.feature +142 -0
- data/features/code_check/W0769.feature +142 -0
- data/features/{message_detection → code_check}/W0780.feature +12 -12
- data/features/code_check/W0781.feature +145 -0
- data/features/{message_detection → code_check}/W0783.feature +8 -8
- data/features/{message_detection → code_check}/W0792.feature +16 -16
- data/features/{message_detection → code_check}/W0793.feature +16 -16
- data/features/{message_detection → code_check}/W0794.feature +10 -10
- data/features/code_check/W0801.feature +84 -0
- data/features/{message_detection → code_check}/W0805.feature +14 -14
- data/features/code_check/W0806.feature +24 -0
- data/features/code_check/W0807.feature +35 -0
- data/features/code_check/W0808.feature +34 -0
- data/features/code_check/W0809.feature +114 -0
- data/features/{message_detection → code_check}/W0811.feature +10 -10
- data/features/{message_detection → code_check}/W0830.feature +12 -12
- data/features/{message_detection → code_check}/W0833.feature +30 -30
- data/features/{message_detection → code_check}/W0834.feature +26 -26
- data/features/{message_detection → code_check}/W1026.feature +8 -8
- data/features/code_check/W1030.feature +84 -0
- data/features/{message_detection → code_check}/W1031.feature +36 -36
- data/features/{message_detection → code_check}/W1039.feature +24 -24
- data/features/{message_detection → code_check}/W1040.feature +8 -8
- data/features/{message_detection → code_check}/W1041.feature +2 -2
- data/features/{message_detection → code_check}/W1046.feature +6 -6
- data/features/{message_detection → code_check}/W1047.feature +12 -12
- data/features/{message_detection → code_check}/W1052.feature +6 -6
- data/features/{message_detection → code_check}/W1066.feature +6 -6
- data/features/{message_detection → code_check}/W1067.feature +6 -6
- data/features/{message_detection → code_check}/W1068.feature +6 -6
- data/features/{message_detection → code_check}/W1069.feature +10 -10
- data/features/{message_detection → code_check}/W1070.feature +15 -15
- data/features/{message_detection → code_check}/W1071.feature +8 -8
- data/features/{message_detection → code_check}/W1072.feature +2 -2
- data/features/{message_detection → code_check}/W1073.feature +14 -14
- data/features/{message_detection → code_check}/W1074.feature +10 -10
- data/features/{message_detection → code_check}/W1075.feature +10 -10
- data/features/{message_detection → code_check}/W1076.feature +8 -8
- data/features/{message_detection → code_check}/W1077.feature +18 -18
- data/features/{message_detection → code_check}/W9001.feature +2 -2
- data/features/{message_detection → code_check}/W9003.feature +12 -12
- data/features/step_definitions/{message_detection_steps.rb → code_check_steps.rb} +1 -1
- data/features/support/env.rb +19 -3
- data/lib/adlint.rb +1 -0
- data/lib/adlint/analyzer.rb +17 -1
- data/lib/adlint/c.rb +0 -4
- data/lib/adlint/c/phase.rb +55 -745
- data/lib/adlint/code.rb +0 -24
- data/lib/adlint/cpp.rb +0 -3
- data/lib/adlint/cpp/phase.rb +50 -112
- data/lib/adlint/driver.rb +2 -2
- data/lib/adlint/error.rb +4 -4
- data/lib/adlint/exam.rb +143 -0
- data/lib/adlint/exam/c_builtin.rb +813 -0
- data/lib/adlint/{c/message.rb → exam/c_builtin/c_check.rb} +2130 -798
- data/lib/adlint/{c/message_shima.rb → exam/c_builtin/c_check_shima.rb} +99 -28
- data/lib/adlint/{c/code.rb → exam/c_builtin/c_code.rb} +31 -5
- data/lib/adlint/{c/metric.rb → exam/c_builtin/c_metric.rb} +43 -11
- data/lib/adlint/{cpp/message.rb → exam/c_builtin/cpp_check.rb} +177 -73
- data/lib/adlint/{cpp/message_shima.rb → exam/c_builtin/cpp_check_shima.rb} +28 -8
- data/lib/adlint/{cpp/code.rb → exam/c_builtin/cpp_code.rb} +14 -3
- data/lib/adlint/{ld/message.rb → exam/c_builtin/ld_check.rb} +33 -12
- data/lib/adlint/{ld/metric.rb → exam/c_builtin/ld_metric.rb} +8 -3
- data/lib/adlint/lang.rb +2 -2
- data/lib/adlint/ld.rb +0 -2
- data/lib/adlint/ld/phase.rb +101 -101
- data/lib/adlint/message.rb +155 -98
- data/lib/adlint/metric.rb +0 -27
- data/lib/adlint/phase.rb +28 -3
- data/lib/adlint/report.rb +22 -12
- data/lib/adlint/traits.rb +97 -5
- data/lib/adlint/util.rb +100 -11
- data/lib/adlint/version.rb +5 -5
- data/share/doc/developers_guide_ja.html +3 -3
- data/share/doc/developers_guide_ja.texi +1 -1
- data/share/doc/users_guide_en.html +1817 -1648
- data/share/doc/users_guide_en.texi +202 -22
- data/share/doc/users_guide_ja.html +1836 -1663
- data/share/doc/users_guide_ja.texi +203 -20
- data/share/sample/bison-2.5/adlint/adlint_traits.yml +55 -2
- data/share/sample/bison-2.5/adlint/lib/adlint_traits.yml +47 -2
- data/share/sample/bison-2.5/adlint/src/adlint_traits.yml +47 -2
- data/share/sample/ctags-5.8/adlint/adlint_traits.yml +47 -2
- data/share/sample/flex-2.5.35/adlint/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/core/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/enc-trans/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/enc/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-bigdecimal/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-continuation/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-coverage/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-curses/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-date/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-dbm/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest-bubblebabble/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest-md5/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest-rmd160/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest-sha1/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest-sha2/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-digest/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-dl-callback/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-dl/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-etc/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-fcntl/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-fiber/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-fiddle/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-gdbm/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-iconv/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-io-console/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-io-nonblock/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-io-wait/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-json-generator/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-json-parser/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-mathn-complex/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-mathn-rational/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-nkf/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-openssl/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-pathname/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-psych/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-pty/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-racc-cparse/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-readline/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-ripper/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-sdbm/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-socket/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-stringio/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-strscan/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-syck/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-syslog/adlint_traits.yml +47 -2
- data/share/sample/ruby-1.9.3-p0/adlint/ext-zlib/adlint_traits.yml +47 -2
- data/share/sample/screen-4.0.3/adlint/adlint_traits.yml +47 -2
- data/share/sample/vim-7.3/adlint/vim/adlint_traits.yml +47 -2
- data/share/sample/vim-7.3/adlint/xxd/adlint_traits.yml +47 -2
- data/share/sample/zsh-4.3.15/adlint/adlint_traits.yml +47 -2
- data/share/sample/zsh-4.3.15/adlint/builtins/adlint_traits.yml +47 -2
- data/share/sample/zsh-4.3.15/adlint/core/adlint_traits.yml +47 -2
- data/share/sample/zsh-4.3.15/adlint/modules/adlint_traits.yml +47 -2
- data/share/sample/zsh-4.3.15/adlint/zle/adlint_traits.yml +47 -2
- data/spec/conf.d/default_traits.yml +56 -3
- metadata +280 -94
- data/etc/mesg.d/en_US/messages.yml +0 -797
- data/etc/mesg.d/ja_JP/messages.yml +0 -797
@@ -3,14 +3,14 @@ Feature: W0645
|
|
3
3
|
W0645 detects that a function parameter is typed as `void'.
|
4
4
|
|
5
5
|
Scenario: a `void' parameter of a `void' function
|
6
|
-
Given a target source named "
|
6
|
+
Given a target source named "fixture.c" with:
|
7
7
|
"""
|
8
8
|
extern void func(a) /* W0645 */
|
9
9
|
void a;
|
10
10
|
{
|
11
11
|
}
|
12
12
|
"""
|
13
|
-
When I successfully run `adlint
|
13
|
+
When I successfully run `adlint fixture.c` on noarch
|
14
14
|
Then the output should exactly match with:
|
15
15
|
| mesg | line | column |
|
16
16
|
| W0117 | 1 | 13 |
|
@@ -21,7 +21,7 @@ Feature: W0645
|
|
21
21
|
| W0628 | 1 | 13 |
|
22
22
|
|
23
23
|
Scenario: a `void' parameter of a `int' function
|
24
|
-
Given a target source named "
|
24
|
+
Given a target source named "fixture.c" with:
|
25
25
|
"""
|
26
26
|
extern int func(a) /* W0645 */
|
27
27
|
void a;
|
@@ -29,7 +29,7 @@ Feature: W0645
|
|
29
29
|
return 0;
|
30
30
|
}
|
31
31
|
"""
|
32
|
-
When I successfully run `adlint
|
32
|
+
When I successfully run `adlint fixture.c` on noarch
|
33
33
|
Then the output should exactly match with:
|
34
34
|
| mesg | line | column |
|
35
35
|
| W0117 | 1 | 12 |
|
@@ -40,7 +40,7 @@ Feature: W0645
|
|
40
40
|
| W0628 | 1 | 12 |
|
41
41
|
|
42
42
|
Scenario: multiple parameters including `void' typed one
|
43
|
-
Given a target source named "
|
43
|
+
Given a target source named "fixture.c" with:
|
44
44
|
"""
|
45
45
|
extern void func(a, b) /* W0645 */
|
46
46
|
int a;
|
@@ -48,7 +48,7 @@ Feature: W0645
|
|
48
48
|
{
|
49
49
|
}
|
50
50
|
"""
|
51
|
-
When I successfully run `adlint
|
51
|
+
When I successfully run `adlint fixture.c` on noarch
|
52
52
|
Then the output should exactly match with:
|
53
53
|
| mesg | line | column |
|
54
54
|
| W0117 | 1 | 13 |
|
@@ -61,14 +61,14 @@ Feature: W0645
|
|
61
61
|
| W0628 | 1 | 13 |
|
62
62
|
|
63
63
|
Scenario: a `void *' parameter
|
64
|
-
Given a target source named "
|
64
|
+
Given a target source named "fixture.c" with:
|
65
65
|
"""
|
66
66
|
extern void func(p) /* OK */
|
67
67
|
void* p;
|
68
68
|
{
|
69
69
|
}
|
70
70
|
"""
|
71
|
-
When I successfully run `adlint
|
71
|
+
When I successfully run `adlint fixture.c` on noarch
|
72
72
|
Then the output should exactly match with:
|
73
73
|
| mesg | line | column |
|
74
74
|
| W0117 | 1 | 13 |
|
@@ -79,14 +79,14 @@ Feature: W0645
|
|
79
79
|
| W0628 | 1 | 13 |
|
80
80
|
|
81
81
|
Scenario: an `int' parameter
|
82
|
-
Given a target source named "
|
82
|
+
Given a target source named "fixture.c" with:
|
83
83
|
"""
|
84
84
|
extern void func(a) /* OK */
|
85
85
|
int a;
|
86
86
|
{
|
87
87
|
}
|
88
88
|
"""
|
89
|
-
When I successfully run `adlint
|
89
|
+
When I successfully run `adlint fixture.c` on noarch
|
90
90
|
Then the output should exactly match with:
|
91
91
|
| mesg | line | column |
|
92
92
|
| W0117 | 1 | 13 |
|
@@ -96,24 +96,24 @@ Feature: W0645
|
|
96
96
|
| W0628 | 1 | 13 |
|
97
97
|
|
98
98
|
Scenario: a `void' as a parameter-type-list
|
99
|
-
Given a target source named "
|
99
|
+
Given a target source named "fixture.c" with:
|
100
100
|
"""
|
101
101
|
extern void func(void); /* OK */
|
102
102
|
"""
|
103
|
-
When I successfully run `adlint
|
103
|
+
When I successfully run `adlint fixture.c` on noarch
|
104
104
|
Then the output should exactly match with:
|
105
105
|
| mesg | line | column |
|
106
106
|
| W0118 | 1 | 13 |
|
107
107
|
|
108
108
|
Scenario: a qualified `void' parameter
|
109
|
-
Given a target source named "
|
109
|
+
Given a target source named "fixture.c" with:
|
110
110
|
"""
|
111
111
|
extern void func(a) /* W0645 */
|
112
112
|
const void a;
|
113
113
|
{
|
114
114
|
}
|
115
115
|
"""
|
116
|
-
When I successfully run `adlint
|
116
|
+
When I successfully run `adlint fixture.c` on noarch
|
117
117
|
Then the output should exactly match with:
|
118
118
|
| mesg | line | column |
|
119
119
|
| W0117 | 1 | 13 |
|
@@ -123,14 +123,14 @@ Feature: W0645
|
|
123
123
|
| W0628 | 1 | 13 |
|
124
124
|
|
125
125
|
Scenario: a more qualified `void' parameter
|
126
|
-
Given a target source named "
|
126
|
+
Given a target source named "fixture.c" with:
|
127
127
|
"""
|
128
128
|
extern void func(a) /* W0645 */
|
129
129
|
const volatile void a;
|
130
130
|
{
|
131
131
|
}
|
132
132
|
"""
|
133
|
-
When I successfully run `adlint
|
133
|
+
When I successfully run `adlint fixture.c` on noarch
|
134
134
|
Then the output should exactly match with:
|
135
135
|
| mesg | line | column |
|
136
136
|
| W0117 | 1 | 13 |
|
@@ -5,11 +5,11 @@ Feature: W0646
|
|
5
5
|
|
6
6
|
Scenario: a string-literal of narrow characters followed by one of wide
|
7
7
|
characters
|
8
|
-
Given a target source named "
|
8
|
+
Given a target source named "fixture.c" with:
|
9
9
|
"""
|
10
10
|
static const char *str = "foo" L"bar"; /* W0646 */
|
11
11
|
"""
|
12
|
-
When I successfully run `adlint
|
12
|
+
When I successfully run `adlint fixture.c` on noarch
|
13
13
|
Then the output should exactly match with:
|
14
14
|
| mesg | line | column |
|
15
15
|
| W0646 | 1 | 32 |
|
@@ -17,22 +17,22 @@ Feature: W0646
|
|
17
17
|
|
18
18
|
Scenario: a string-literal of narrow characters followed by a compatible
|
19
19
|
string-literal
|
20
|
-
Given a target source named "
|
20
|
+
Given a target source named "fixture.c" with:
|
21
21
|
"""
|
22
22
|
static const char *str = "foo" "bar"; /* OK */
|
23
23
|
"""
|
24
|
-
When I successfully run `adlint
|
24
|
+
When I successfully run `adlint fixture.c` on noarch
|
25
25
|
Then the output should exactly match with:
|
26
26
|
| mesg | line | column |
|
27
27
|
| W0947 | 1 | 26 |
|
28
28
|
|
29
29
|
Scenario: a string-literal of wide characters followed by one of narrow
|
30
30
|
characters
|
31
|
-
Given a target source named "
|
31
|
+
Given a target source named "fixture.c" with:
|
32
32
|
"""
|
33
33
|
static const char *str = L"foo" "bar"; /* W0646 */
|
34
34
|
"""
|
35
|
-
When I successfully run `adlint
|
35
|
+
When I successfully run `adlint fixture.c` on noarch
|
36
36
|
Then the output should exactly match with:
|
37
37
|
| mesg | line | column |
|
38
38
|
| W0646 | 1 | 33 |
|
@@ -42,11 +42,11 @@ Feature: W0646
|
|
42
42
|
|
43
43
|
Scenario: a string-literal of wide characters followed by a compatible
|
44
44
|
string-literal
|
45
|
-
Given a target source named "
|
45
|
+
Given a target source named "fixture.c" with:
|
46
46
|
"""
|
47
47
|
static const char *str = L"foo" L"bar"; /* OK */
|
48
48
|
"""
|
49
|
-
When I successfully run `adlint
|
49
|
+
When I successfully run `adlint fixture.c` on noarch
|
50
50
|
Then the output should exactly match with:
|
51
51
|
| mesg | line | column |
|
52
52
|
| W9003 | 1 | 26 |
|
@@ -55,42 +55,42 @@ Feature: W0646
|
|
55
55
|
|
56
56
|
Scenario: a string-literal of narrow characters followed by one of wide
|
57
57
|
characters those are replaced by macros
|
58
|
-
Given a target source named "
|
58
|
+
Given a target source named "fixture.c" with:
|
59
59
|
"""
|
60
60
|
#define STR1 "foo"
|
61
61
|
#define STR2 L"bar"
|
62
62
|
|
63
63
|
static const char *str = STR1 STR2; /* W0646 */
|
64
64
|
"""
|
65
|
-
When I successfully run `adlint
|
65
|
+
When I successfully run `adlint fixture.c` on noarch
|
66
66
|
Then the output should exactly match with:
|
67
67
|
| mesg | line | column |
|
68
68
|
| W0646 | 4 | 31 |
|
69
69
|
|
70
70
|
Scenario: a string-literal of narrow characters followed by a compatible
|
71
71
|
string-literal those are replaced by macros
|
72
|
-
Given a target source named "
|
72
|
+
Given a target source named "fixture.c" with:
|
73
73
|
"""
|
74
74
|
#define STR1 "foo"
|
75
75
|
#define STR2 "bar"
|
76
76
|
|
77
77
|
static const char *str = STR1 STR2; /* OK */
|
78
78
|
"""
|
79
|
-
When I successfully run `adlint
|
79
|
+
When I successfully run `adlint fixture.c` on noarch
|
80
80
|
Then the output should exactly match with:
|
81
81
|
| mesg | line | column |
|
82
82
|
| W0947 | 1 | 26 |
|
83
83
|
|
84
84
|
Scenario: a string-literal of wide characters followed by one of narrow
|
85
85
|
characters those are replaced by macros
|
86
|
-
Given a target source named "
|
86
|
+
Given a target source named "fixture.c" with:
|
87
87
|
"""
|
88
88
|
#define STR1 L"foo"
|
89
89
|
#define STR2 "bar"
|
90
90
|
|
91
91
|
static const char *str = STR1 STR2; /* W0646 */
|
92
92
|
"""
|
93
|
-
When I successfully run `adlint
|
93
|
+
When I successfully run `adlint fixture.c` on noarch
|
94
94
|
Then the output should exactly match with:
|
95
95
|
| mesg | line | column |
|
96
96
|
| W0646 | 4 | 31 |
|
@@ -99,14 +99,14 @@ Feature: W0646
|
|
99
99
|
|
100
100
|
Scenario: a string-literal of wide characters followed by a compatible
|
101
101
|
string-literal those are replaced by macros
|
102
|
-
Given a target source named "
|
102
|
+
Given a target source named "fixture.c" with:
|
103
103
|
"""
|
104
104
|
#define STR1 L"foo"
|
105
105
|
#define STR2 L"bar"
|
106
106
|
|
107
107
|
static const char *str = STR1 STR2; /* OK */
|
108
108
|
"""
|
109
|
-
When I successfully run `adlint
|
109
|
+
When I successfully run `adlint fixture.c` on noarch
|
110
110
|
Then the output should exactly match with:
|
111
111
|
| mesg | line | column |
|
112
112
|
| W9003 | 4 | 26 |
|
@@ -4,14 +4,14 @@ Feature: W0649
|
|
4
4
|
a constant-expression of negative value.
|
5
5
|
|
6
6
|
Scenario: left shift-expression with negative constant rhs value
|
7
|
-
Given a target source named "
|
7
|
+
Given a target source named "fixture.c" with:
|
8
8
|
"""
|
9
9
|
int foo(int i)
|
10
10
|
{
|
11
11
|
return i << -1; /* W0649 */
|
12
12
|
}
|
13
13
|
"""
|
14
|
-
When I successfully run `adlint
|
14
|
+
When I successfully run `adlint fixture.c` on noarch
|
15
15
|
Then the output should exactly match with:
|
16
16
|
| mesg | line | column |
|
17
17
|
| W0117 | 1 | 5 |
|
@@ -23,14 +23,14 @@ Feature: W0649
|
|
23
23
|
| W0628 | 1 | 5 |
|
24
24
|
|
25
25
|
Scenario: right shift-expression with negative constant rhs value
|
26
|
-
Given a target source named "
|
26
|
+
Given a target source named "fixture.c" with:
|
27
27
|
"""
|
28
28
|
int foo(int i)
|
29
29
|
{
|
30
30
|
return i >> -1; /* W0649 */
|
31
31
|
}
|
32
32
|
"""
|
33
|
-
When I successfully run `adlint
|
33
|
+
When I successfully run `adlint fixture.c` on noarch
|
34
34
|
Then the output should exactly match with:
|
35
35
|
| mesg | line | column |
|
36
36
|
| W0117 | 1 | 5 |
|
@@ -42,7 +42,7 @@ Feature: W0649
|
|
42
42
|
|
43
43
|
Scenario: left shift-expression with negative constant rhs value derived by
|
44
44
|
macro
|
45
|
-
Given a target source named "
|
45
|
+
Given a target source named "fixture.c" with:
|
46
46
|
"""
|
47
47
|
#define VAL (-1)
|
48
48
|
|
@@ -51,7 +51,7 @@ Feature: W0649
|
|
51
51
|
return i << VAL; /* W0649 */
|
52
52
|
}
|
53
53
|
"""
|
54
|
-
When I successfully run `adlint
|
54
|
+
When I successfully run `adlint fixture.c` on noarch
|
55
55
|
Then the output should exactly match with:
|
56
56
|
| mesg | line | column |
|
57
57
|
| W0117 | 3 | 5 |
|
@@ -64,7 +64,7 @@ Feature: W0649
|
|
64
64
|
|
65
65
|
Scenario: right shift-expression with negative constant rhs value derived by
|
66
66
|
macro
|
67
|
-
Given a target source named "
|
67
|
+
Given a target source named "fixture.c" with:
|
68
68
|
"""
|
69
69
|
#define VAL (-1)
|
70
70
|
|
@@ -73,7 +73,7 @@ Feature: W0649
|
|
73
73
|
return i >> VAL; /* W0649 */
|
74
74
|
}
|
75
75
|
"""
|
76
|
-
When I successfully run `adlint
|
76
|
+
When I successfully run `adlint fixture.c` on noarch
|
77
77
|
Then the output should exactly match with:
|
78
78
|
| mesg | line | column |
|
79
79
|
| W0117 | 3 | 5 |
|
@@ -84,14 +84,14 @@ Feature: W0649
|
|
84
84
|
| W0628 | 3 | 5 |
|
85
85
|
|
86
86
|
Scenario: left shift-expression with positive constant rhs value
|
87
|
-
Given a target source named "
|
87
|
+
Given a target source named "fixture.c" with:
|
88
88
|
"""
|
89
89
|
int foo(int i)
|
90
90
|
{
|
91
91
|
return i << 1; /* OK */
|
92
92
|
}
|
93
93
|
"""
|
94
|
-
When I successfully run `adlint
|
94
|
+
When I successfully run `adlint fixture.c` on noarch
|
95
95
|
Then the output should exactly match with:
|
96
96
|
| mesg | line | column |
|
97
97
|
| W0117 | 1 | 5 |
|
@@ -102,14 +102,14 @@ Feature: W0649
|
|
102
102
|
| W0628 | 1 | 5 |
|
103
103
|
|
104
104
|
Scenario: right shift-expression with positive constant rhs value
|
105
|
-
Given a target source named "
|
105
|
+
Given a target source named "fixture.c" with:
|
106
106
|
"""
|
107
107
|
int foo(int i)
|
108
108
|
{
|
109
109
|
return i >> 1; /* OK */
|
110
110
|
}
|
111
111
|
"""
|
112
|
-
When I successfully run `adlint
|
112
|
+
When I successfully run `adlint fixture.c` on noarch
|
113
113
|
Then the output should exactly match with:
|
114
114
|
| mesg | line | column |
|
115
115
|
| W0117 | 1 | 5 |
|
@@ -119,14 +119,14 @@ Feature: W0649
|
|
119
119
|
| W0628 | 1 | 5 |
|
120
120
|
|
121
121
|
Scenario: left shift-expression with zero constant rhs value
|
122
|
-
Given a target source named "
|
122
|
+
Given a target source named "fixture.c" with:
|
123
123
|
"""
|
124
124
|
int foo(int i)
|
125
125
|
{
|
126
126
|
return i << 0; /* OK */
|
127
127
|
}
|
128
128
|
"""
|
129
|
-
When I successfully run `adlint
|
129
|
+
When I successfully run `adlint fixture.c` on noarch
|
130
130
|
Then the output should exactly match with:
|
131
131
|
| mesg | line | column |
|
132
132
|
| W0117 | 1 | 5 |
|
@@ -137,14 +137,14 @@ Feature: W0649
|
|
137
137
|
| W0628 | 1 | 5 |
|
138
138
|
|
139
139
|
Scenario: right shift-expression with zero constant rhs value
|
140
|
-
Given a target source named "
|
140
|
+
Given a target source named "fixture.c" with:
|
141
141
|
"""
|
142
142
|
int foo(int i)
|
143
143
|
{
|
144
144
|
return i >> 0; /* OK */
|
145
145
|
}
|
146
146
|
"""
|
147
|
-
When I successfully run `adlint
|
147
|
+
When I successfully run `adlint fixture.c` on noarch
|
148
148
|
Then the output should exactly match with:
|
149
149
|
| mesg | line | column |
|
150
150
|
| W0117 | 1 | 5 |
|
@@ -155,14 +155,14 @@ Feature: W0649
|
|
155
155
|
|
156
156
|
Scenario: left shift compound-assignment-expression with negative constant
|
157
157
|
rhs value
|
158
|
-
Given a target source named "
|
158
|
+
Given a target source named "fixture.c" with:
|
159
159
|
"""
|
160
160
|
void foo(int i)
|
161
161
|
{
|
162
162
|
i <<= -1; /* W0649 */
|
163
163
|
}
|
164
164
|
"""
|
165
|
-
When I successfully run `adlint
|
165
|
+
When I successfully run `adlint fixture.c` on noarch
|
166
166
|
Then the output should exactly match with:
|
167
167
|
| mesg | line | column |
|
168
168
|
| W0117 | 1 | 6 |
|
@@ -174,14 +174,14 @@ Feature: W0649
|
|
174
174
|
|
175
175
|
Scenario: right shift compound-assignment-expression with negative constant
|
176
176
|
rhs value
|
177
|
-
Given a target source named "
|
177
|
+
Given a target source named "fixture.c" with:
|
178
178
|
"""
|
179
179
|
void foo(int i)
|
180
180
|
{
|
181
181
|
i >>= -1; /* W0649 */
|
182
182
|
}
|
183
183
|
"""
|
184
|
-
When I successfully run `adlint
|
184
|
+
When I successfully run `adlint fixture.c` on noarch
|
185
185
|
Then the output should exactly match with:
|
186
186
|
| mesg | line | column |
|
187
187
|
| W0117 | 1 | 6 |
|
@@ -192,7 +192,7 @@ Feature: W0649
|
|
192
192
|
|
193
193
|
Scenario: left shift-expression with negative constant rhs value derived by
|
194
194
|
enumerator
|
195
|
-
Given a target source named "
|
195
|
+
Given a target source named "fixture.c" with:
|
196
196
|
"""
|
197
197
|
enum e { VAL = -2 };
|
198
198
|
|
@@ -201,7 +201,7 @@ Feature: W0649
|
|
201
201
|
return i << VAL; /* W0649 */
|
202
202
|
}
|
203
203
|
"""
|
204
|
-
When I successfully run `adlint
|
204
|
+
When I successfully run `adlint fixture.c` on noarch
|
205
205
|
Then the output should exactly match with:
|
206
206
|
| mesg | line | column |
|
207
207
|
| W0117 | 3 | 5 |
|
@@ -214,7 +214,7 @@ Feature: W0649
|
|
214
214
|
|
215
215
|
Scenario: right shift-expression with negative constant rhs value derived by
|
216
216
|
enumerator
|
217
|
-
Given a target source named "
|
217
|
+
Given a target source named "fixture.c" with:
|
218
218
|
"""
|
219
219
|
enum e { VAL = -2 };
|
220
220
|
|
@@ -223,7 +223,7 @@ Feature: W0649
|
|
223
223
|
return i >> VAL; /* W0649 */
|
224
224
|
}
|
225
225
|
"""
|
226
|
-
When I successfully run `adlint
|
226
|
+
When I successfully run `adlint fixture.c` on noarch
|
227
227
|
Then the output should exactly match with:
|
228
228
|
| mesg | line | column |
|
229
229
|
| W0117 | 3 | 5 |
|
@@ -235,7 +235,7 @@ Feature: W0649
|
|
235
235
|
|
236
236
|
Scenario: left shift-expression with positive constant rhs value derived by
|
237
237
|
enumerator
|
238
|
-
Given a target source named "
|
238
|
+
Given a target source named "fixture.c" with:
|
239
239
|
"""
|
240
240
|
enum e { VAL = 2 };
|
241
241
|
|
@@ -244,7 +244,7 @@ Feature: W0649
|
|
244
244
|
return i << VAL; /* OK */
|
245
245
|
}
|
246
246
|
"""
|
247
|
-
When I successfully run `adlint
|
247
|
+
When I successfully run `adlint fixture.c` on noarch
|
248
248
|
Then the output should exactly match with:
|
249
249
|
| mesg | line | column |
|
250
250
|
| W0117 | 3 | 5 |
|
@@ -256,7 +256,7 @@ Feature: W0649
|
|
256
256
|
|
257
257
|
Scenario: right shift-expression with positive constant rhs value derived by
|
258
258
|
enumerator
|
259
|
-
Given a target source named "
|
259
|
+
Given a target source named "fixture.c" with:
|
260
260
|
"""
|
261
261
|
enum e { VAL = 2 };
|
262
262
|
|
@@ -265,7 +265,7 @@ Feature: W0649
|
|
265
265
|
return i >> VAL; /* OK */
|
266
266
|
}
|
267
267
|
"""
|
268
|
-
When I successfully run `adlint
|
268
|
+
When I successfully run `adlint fixture.c` on noarch
|
269
269
|
Then the output should exactly match with:
|
270
270
|
| mesg | line | column |
|
271
271
|
| W0117 | 3 | 5 |
|