So I’m just tinkering around with C++. Not my primary language.
Every time I create a new project in VS code using the template generator the build fails with multiple errors. Is this normal. I haven’t even written any code yet and the build fails.
Did a fresh installation of WPILib’s VS code. Don’t see anything in the docs having to do anything special. Latest build, Windows 10, log file included below
See file:///C:/Users/Public/wpilib/test/build/tmp/compileFrcUserProgramTestWindowsx86-64ReleaseGoogleTestExeFrcUserProgramCpp/output.txt for all output for compileFrcUserProgramTestWindowsx86-64ReleaseGoogleTestExeFrcUserProgramCpp.
compiling Robot.cpp failed.
Robot.cpp
C:\Users\Public\wpilib\test\src\main\include\Robot.h(7): fatal error C1083: Cannot open include file: ‘optional’: No such file or directory
cl : Command line warning D9002 : ignoring unknown option ‘/std:c++20’
cl : Command line warning D9002 : ignoring unknown option ‘/permissive-’
cl : Command line warning D9002 : ignoring unknown option ‘/Zc:__cplusplus’
cl : Command line warning D9002 : ignoring unknown option ‘/Zc:preprocessor’
compiling RobotContainer.cpp failed.
RobotContainer.cpp
C:\Users\neeba.gradle\caches\transforms-3\9c6bb2103a3d82450f87644c2c782003\transformed\wpilibNewCommands-cpp-2023.4.3-headers\frc2/command/CommandPtr.h(10): fatal error C1083: Cannot open include file: ‘span’: No such file or directory
cl : Command line warning D9002 : ignoring unknown option ‘/std:c++20’
cl : Command line warning D9002 : ignoring unknown option ‘/permissive-’
cl : Command line warning D9002 : ignoring unknown option ‘/Zc:__cplusplus’
cl : Command line warning D9002 : ignoring unknown option ‘/Zc:preprocessor’
Finished compileFrcUserProgramTestWindowsx86-64ReleaseGoogleTestExeFrcUserProgramCpp, see full log file:///C:/Users/Public/wpilib/test/build/tmp/compileFrcUserProgramTestWindowsx86-64ReleaseGoogleTestExeFrcUserProgramCpp/output.txt.