Skip to content

Commit b493c12

Browse files
author
Colin Robertson
committed
Two H2 headers
1 parent a511441 commit b493c12

File tree

1 file changed

+5
-1
lines changed
  • docs/error-messages/compiler-warnings

1 file changed

+5
-1
lines changed

docs/error-messages/compiler-warnings/C4464.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,11 @@ ms.workload: ["cplusplus"]
1616

1717
> **relative include path contains '..'**
1818
19-
A `#include` directive has a path that includes a '..' parent directory specifier. Starting in Visual Studio 2015 Update 1, the compiler can detect this and issue a warning, if enabled. Code written in this way is usually intended to include headers that exist outside of the project by incorrectly using project-relative paths. This creates a risk that the program could be compiled by including a different source file than the programmer intends, or that these relative paths would not be portable to other build environments. Although there is no specific warning for it, we also recommend that you do not use a parent directory path segment to specify your project include directories.
19+
A `#include` directive has a path that includes a '..' parent directory specifier.
20+
21+
## Remarks
22+
23+
Starting in Visual Studio 2015 Update 1, the compiler can detect an include directive that contains a '..' path segment and issue a warning, if enabled. Code written in this way is usually intended to include headers that exist outside of the project by incorrectly using project-relative paths. This creates a risk that the program could be compiled by including a different source file than the programmer intends, or that these relative paths would not be portable to other build environments. Although there is no specific warning for it, we also recommend that you do not use a parent directory path segment to specify your project include directories.
2024

2125
This warning is new in Visual Studio 2015 Update 1, and is off by default. Use [/Wall](../../build/reference/compiler-option-warning-level.md) to enable all warnings that are off by default, or __/w__*n*__4464__ to enable C4464 as a level *n* warning. For more information, see [Compiler Warnings That Are Off By Default](../../preprocessor/compiler-warnings-that-are-off-by-default.md). For information on how to disable warnings by compiler version, see [Compiler warnings by compiler version](compiler-warnings-by-compiler-version.md).
2226

0 commit comments

Comments
 (0)