
In the 'single-file-parse' mode, seeing `#include UNDEFINED_IDENTIFIER` should not be treated as an error. The identifier might be defined in a header that we decided to skip, resulting in a nonsensical diagnostic from the user point of view.
11 lines
302 B
C
11 lines
302 B
C
// RUN: split-file %s %t
|
|
// RUN: c-index-test -single-file-parse %t/tu.c 2>&1 | FileCheck --allow-empty %t/tu.c
|
|
|
|
//--- header1.h
|
|
#define HEADER2_H "header2.h"
|
|
//--- header2.h
|
|
//--- tu.c
|
|
#include "header1.h"
|
|
// CHECK-NOT: tu.c:[[@LINE+1]]:10: error: expected "FILENAME" or <FILENAME>
|
|
#include HEADER2_H
|