formatting c++ file with clang-format in vscode doesn´t work - clang-format

I´m getting the error message:
YAML:58:21: error: unknown key 'IncludeIsMainRegex'
IncludeIsMainRegex: '$'
Error reading ~/path/to/c++/project/.clang-format: Invalid argument
in vscode when I try to format the cpp file with clang format does anybody how to fix it ?

Related

Bazel not building correctly. Error with os.bzl

I've pulled the most recent drake repo "https://github.com/RobotLocomotion/drake" and I am trying to
$run bazel build //...
but bazel is returning the following error
ERROR: /home/nathan/drake/tools/workspace/os.bzl:73:13: invalid escape sequence: \(. You can enable unknown escape sequences by passing the flag --incompatible_restrict_string_escapes=false ERROR: /home/nathan/drake/tools/workspace/os.bzl:73:19: invalid escape sequence: \|. You can enable unknown escape sequences by passing the flag --incompatible_restrict_string_escapes=false ERROR: /home/nathan/drake/tools/workspace/os.bzl:73:31: invalid escape sequence: \). You can enable unknown escape sequences by passing the flag --incompatible_restrict_string_escapes=false ERROR: error loading package '': in /home/nathan/drake/tools/workspace/default.bzl: in /home/nathan/drake/tools/workspace/blas/repository.bzl: Extension 'tools/workspace/os.bzl' has errors INFO: Elapsed time: 0.139s INFO: 0 processes. FAILED: Build did NOT complete successfully (0 packages loaded).
It seems to not like line 73 in os.bzl, but I'm not sure how to fix it. Any suggestions would be very helpful.
I've just run a build using those same versions of Bazel, Ubuntu, and Drake, with no problems.
There was a problem on that line several months ago, that we fixed in https://github.com/RobotLocomotion/drake/pull/12696. Can you confirm you're using a new-enough version of Drake? For example, what does git log -1 report?

LLVM ERROR: Error parsing inline asm, unexpected token

I am new to LLVM and clang. I am working on a tool that uses LLVM/clang in the backend as a compiler. With the recent changes in LLVM tool, I have started getting following error:
<inline asm>:1:13: error: unexpected token in argument list
lock addb 2$2, 1048576
^
LLVM ERROR: Error parsing inline asm
I do not have any idea how to resolve this. Any input is appreciated.

.cmake : fatal error LNK1107: invalid or corrupt file: cannot read at 0x1B1

am trying to build a openCV application in c++ using VisualStudio2017
debugging gives me the following error:
C:\opencv\build\install\x64\vc15\lib\OpenCVConfig-version.cmake
: fatal error LNK1107: invalid or corrupt file: cannot read at 0x1B1 `
i used the following link for installation
https://www.youtube.com/watch?v=mdeP8SdvSJw
i did refer to the different answers on this topic here. but, couldn't find the solution regarding cmake.

install ZeosLib on xe5

i found this project for connecting to mysql servers!
: http://sourceforge.net/projects/zeoslib/
but for installing on XE5 i got the flowing error :
[dcc32 Fatal Error] ZCore.dpk(56): F1026 File not found: 'C:\Users\peiman\Desktop\rad\mysql\packages\DelphiXE5\ZFastCode.dcu'
i searched the file for ZFastCode.dcu but there isnt any file with this name in all parts of the projects
any body know how can i fix this!?
just Remove line for ZFastCode.pas from your ZCore package file.

rebuilding opencv 2.1 debian package

I'm trying to rebuild the debian package for opencv 2.1,to create a package for armel supporting hard-float.I was following this guide,but when I use the command debuild -us -uc -aarmel I get the following error when it's trying to read the CMakeLists.txt file:
CMake Error: Error in cmake code at
/home/rodrigo/tmp/opencv-2.1.0/CMakeLists.txt:1214:
Parse error. Function missing ending ")". Instead found unterminated string with text ")
#----------------------------------------------------------------------------
# Generate the OpenCVConfig.cmake file for unix
# installation in CMAKE_INSTALL_PREFIX
#----------------------------------------------------------------------------
".
-- Configuring incomplete, errors occurred!
It is giving me an strange error on the end of the file,as if I'm missing a ")" on the end of a function,which is not the case,as you can see on the complete CMakeLists.txt file.
I don't have much experience with rebuilding packages from source.Has anyone seen this error before?
I had the same problem and it turned out to be mismatched quote characters. I had been editing the CMakeLists file using textEdit on the Mac and it inserted a right double quotation mark rather than a neutral double quotation mark, which is what was at the other end of the string.
As a result the string had quotes at each end but the quotes didn't match, hence the error.

Resources