class AdLint::Exam::CBuiltin::W1026

Public Class Methods

new(phase_ctxt) click to toggle source
Calls superclass method AdLint::Examination::new
# File lib/adlint/exam/c_builtin/cc1_check.rb, line 20471
def initialize(phase_ctxt)
  super
  interp = phase_ctxt[:cc1_interpreter]
  interp.on_function_call_expr_evaled += T(:check)
end

Private Instance Methods

check(expr, fun, arg_vars, *) click to toggle source
# File lib/adlint/exam/c_builtin/cc1_check.rb, line 20478
def check(expr, fun, arg_vars, *)
  arg_exprs = expr.argument_expressions
  arg_exprs.zip(arg_vars).each_with_index do |(arg_expr, var), idx|
    W(arg_expr.location, idx + 1) if var.type.incomplete?
  end
end