#include指令:相对于哪里? [英] #include directive: relative to where?

查看:166
本文介绍了#include指令:相对于哪里?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我查看了 C ++编程语言以试图找到答案。当我在标题中 #includemy_dir / my_header.hpp时,它在哪里查找此文件?相对于包含它的源文件或其他内容,它是相对于标题吗?

I have looked in The C++ Programming Language to try to find the answer to this. When I #include "my_dir/my_header.hpp" in a header, where does it look for this file? Is it relative to the header, relative to the source file that included it, or something else?

推荐答案

实现已定义。请参阅 #include< filename>之间的区别和#includefilename

这篇关于#include指令:相对于哪里?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆