Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => Topic started by: gd_on on August 16, 2025, 11:25:47 am

Title: Error when compiling parser.cpp in svn 13708
Post by: gd_on on August 16, 2025, 11:25:47 am
Quote
C:\Users\Gerard\Documents\CodeBlocks_SVN\CodeBlocks_src\src\plugins\contrib\clangd_client\src\codecompletion\parser\parser.cpp|1662|error: operands to '?:' have different types 'size_t' {aka 'long long unsigned int'} and 'std::nullptr_t'|
This error is obtained with MingW64 / Msys2 g++ 15.2 on Windows. Adding an explicit cast to site_t before nullptr corrects the compilation error. But is it the correct solution ?
Title: Re: Error when compiling parser.cpp in svn 13708
Post by: christo on August 16, 2025, 12:20:33 pm
In the patch I provided in https://sourceforge.net/p/codeblocks/code/13708 it was
Code
size_t remainingToParse = pParser ? pParser->GetFilesRemainingToParse() : 0;

I think we should change nullptr back to 0 as above.
Title: Re: Error when compiling parser.cpp in svn 13708
Post by: Miguel Gimenez on August 16, 2025, 12:58:33 pm
Fixed in r13710 (https://sourceforge.net/p/codeblocks/code/13710).