예제 #1
0
void test_function_call() {
  test_function(0);
  // CHECK: test_function(nullptr);

  test_function(NULL);
  // CHECK: test_function(nullptr);

  test_function(g_null);
  // CHECK: test_function(nullptr);

  test_function_no_ptr_param(0);
  // CHECK: test_function_no_ptr_param(0);
}
void test_function_call() {
  test_function(0);
  // CHECK-MESSAGES: :[[@LINE-1]]:17: warning: use nullptr
  // CHECK-FIXES: test_function(nullptr);

  test_function(NULL);
  // CHECK-MESSAGES: :[[@LINE-1]]:17: warning: use nullptr
  // CHECK-FIXES: test_function(nullptr);

  test_function(g_null);
  // CHECK-MESSAGES: :[[@LINE-1]]:17: warning: use nullptr
  // CHECK-FIXES: test_function(nullptr);

  test_function_no_ptr_param(0);
}