草庐IT

tfs-2015

全部标签

c++ - 如何在 Visual Studio 2015 中更新我的 C++ 项目以使用新的通用 CRT?

在VS2015将我的项目更新到新的平台工具集v140后,由于链接器错误,它无法构建:LNK1104无法打开文件“libucrt.lib”。由于本文中提到的新通用CRT,该库似乎已被移动:http://blogs.msdn.com/b/vcblog/archive/2015/03/03/introducing-the-universal-crt.aspx?PageIndex=2.虽然文章确实告诉我现在应该链接到什么,但它没有提供如何链接的说明。我的解决方案会生成一个.exe和一个它使用的.dll。我不知道如何处理文章下面描述的矩阵。发布DLL(/MD):msvcrt.libvcrunti

c++ - 将 bool 和 int 的引用与 MSVC 2015 进行比较时发出警告

以下代码使用MSVC(2015更新3)生成警告-使用/W4:constbool&a=true;constint&b=1;if(a==b)C4805:“==”:“constbool”类型和“constint”类型在操作中的不安全混合但没有引用它可以干净地编译。constboola=true;constintb=1;if(a==b)为什么?编辑:也只是在没有const的情况下测试过boola=true;intb=1;if(a==b)警告再次出现...编辑2:在Debug中编译...我确实不得不在constnoref情况下使C4127:conditionalexpressionisconst

c++ - 为什么此代码链接到 Intel Compiler 2015 而不是 Intel Compiler 2018?

我的团队最近从2015年英特尔编译器(并行工作室)升级到2018年版本,我们遇到了一个链接器问题,让每个人都焦头烂额。我有以下类(为简洁起见进行了适度编辑),用于处理子进程的包装以及与它们对话的相关文件描述符:classSubprocWrapper{public:staticconstintPASSTHRU_FD=0;staticconstintMAKE_PIPE=-1;typedefstd::mapEnvMapType;staticEnvMapTypegetMyEnv();SubprocWrapper(intstdin_fd_req,intstdout_fd_req,intstder

c++ - Visual Studio 2015 C++ 应用程序需要客户端客户端上的 api-ms-win-crt-runtime-l1-1-0.dll

我使用VisualStudio2015社区版构建了一个应用程序。当我的一些用户尝试运行它时,他们收到以下错误:Theprogramcan'tstartbecauseapi-ms-win-crt-runtime-l1-1-0.dllismissingfromyourcomputer.Tryreinstallingtheprogramtofixthisproblem.很明显,这可以通过安装UpdateforUniversalCRuntimeinWindows来解决。(KB2999226)。我可以在安装脚本期间检查修补程序,但我发现的所有方法都是toosloworunreliable.如何防

c++ - Visual Studio 2015 社区 - 'Visual C++ Project System Package' 错误

所以,这个问题我已经有一段时间了。当我尝试打开我的任何项目时,经常会收到以下错误:---------------------------MicrosoftVisualStudio---------------------------The'VisualC++ProjectSystemPackage'packagedidnotloadcorrectly.Theproblemmayhavebeencausedbyaconfigurationchangeorbytheinstallationofanotherextension.Youcangetmoreinformationbyexamin

c++ - 为什么 valarray 在 Visual Studio 2015 上这么慢?

为了加快库中的计算速度,我决定使用std::valarray类。documentation说:std::valarrayandhelperclassesaredefinedtobefreeofcertainformsofaliasing,thusallowingoperationsontheseclassestobeoptimizedsimilartotheeffectofthekeywordrestrictintheCprogramminglanguage.Inaddition,functionsandoperatorsthattakevalarrayargumentsareallo

c++ - 如何在 Visual Studio 2015 社区上安装 Visual Studio Build Tools 2010?

我在VisualStudio2010上创建了一个项目。当我尝试在VisualStudio2015社区版上运行该项目时,我收到以下错误,SeverityCodeDescriptionProjectFileLineErrorMSB8020ThebuildtoolsforVisualStudio2010(PlatformToolset='v100')cannotbefound.Tobuildusingthev100buildtools,pleaseinstallVisualStudio2010buildtools.Alternatively,youmayupgradetothecurrent

c++ - 错误 C4592:符号将被动态初始化。 VS2015.1 静态常量 std::vector 字段

更新VS2015.1后下一个代码不再编译:classtestClass{staticconststd::vectortest;};初始化conststd::vectortestClass::test={1,2};有错误:errorC4592:'test':符号将被动态初始化(实现限制)是错误还是编译器发生了某些变化? 最佳答案 VC++编译器开发在这里。PeterRuderman的回答几乎是正确的。该警告实际上是针对constexpr对象,其中constexpr构造函数调用涉及初始化。在Update1中,我们现在可以使用conste

c++ - void_t 在 Visual Studio 2015 上失败

我不明白为什么以下测试在VisualStudio2015中总是失败(static_assert触发器):#includeusingnamespacestd;templateusingtry_assign=decltype(declval()=declval());templatestructmy_is_copy_assignable:false_type{};templatestructmy_is_copy_assignable>>:true_type{};intmain(){static_assert(my_is_copy_assignable::value,"fail");retu

c++ - Visual Studio 2015 探查器未显示我的代码中的任何内容

我正在尝试使用VisualStudio2015社区的分析器来计算CPU使用率,我得到的只是我的exe和[外部代码],没有别的:生成了一个pdb文件,我尝试清理和重建我的项目,只禁用了我的代码;有人可以帮助我吗?谢谢。 最佳答案 试试这个:Debug->StartDiagnosticToolswithoutDebugger并从那里选择PerformanceWizard而不是CPUUsage,并且只能从那里选择您需要的CPU或其他选项,这解决了我的问题。 关于c++-VisualStudio