class AdLint::Exam::CBuiltin::W0688
Public Class Methods
new(phase_ctxt)
click to toggle source
Calls superclass method
AdLint::Examination::new
# File lib/adlint/exam/c_builtin/cpp_check.rb, line 1175 def initialize(phase_ctxt) super trav = phase_ctxt[:cpp_ast_traversal] trav.enter_line_line += T(:check) end
Private Instance Methods
check(line_line)
click to toggle source
# File lib/adlint/exam/c_builtin/cpp_check.rb, line 1182 def check(line_line) if line_no_arg = line_no_argument(line_line) line_no = Integer(line_no_arg.value) unless line_no > 0 && line_no < 32768 W(line_no_arg.location) end end rescue end
line_no_argument(line_line)
click to toggle source
# File lib/adlint/exam/c_builtin/cpp_check.rb, line 1192 def line_no_argument(line_line) line_line.pp_tokens ? line_line.pp_tokens.tokens.first : nil end