bloomberg/bde

bblb_schedulegenerationutil.cpp .Error: The function "abs" must have a prototype.

avysotsk opened this issue · 3 comments

Compilation of file bblb_schedulegenerationutil.cpp fails with error message
"../groups/bbl/bblb/bblb_schedulegenerationutil.cpp", line 253: Error: The function "abs" must have a prototype.

Fix is to change line 253 of file groups/bbl/bblb/bblb_schedulegenerationutil.cpp
from
schedule->reserve(abs(endCount - startCount) + 1);
to
schedule->reserve(bsl::abs(endCount - startCount) + 1);

I haven't been able to reproduce this. Can you supply the following information?

Platform:
Compiler:
Compiler version:
BDE build configuration (i.e. -t argument for waf; -DBSL_OVERRIDES_STD or not):

Platform: SPARC Solaris 11.3
Compiler: Oracle Developer Studio
Compiler version: 12.5
BDE build configuration (i.e. -t argument for waf; -DBSL_OVERRIDES_STD or not):
$ CXX=CC waf configure --check-c-compiler=suncc --check-cxx-compiler=suncxx --library-type=shared --build-type=release

Full line to reproduce:
$ CC -library=stlport4 -DBDE_BUILD_TARGET_STLPORT -template=no%extdef -xcode=pic32 -m64 -xtarget=generic -DBDE_BUILD_TARGET_EXC -DBDE_BUILD_TARGET_MT -DBDE_BUILD_TARGET_OPT -m64 -xtarget=generic -xthreadvar=dynamic -xannotate=no -features=except -xO3 -DNDEBUG -xbuiltin=%all -D_POSIX_PTHREAD_SEMANTICS -mt -DBSLS_IDENT_OFF -xcode=pic32 -DPIC -I/bde/groups/bbl/bblb -I/bde/groups/bbl/bblscm -I/bde/groups/bdl/bdlscm -I/bde/groups/bdl/bdlf -I/bde/groups/bdl/bdlb -I/bde/groups/bdl/bdlsb -I/bde/groups/bdl/bdlde -I/bde/groups/bdl/bdlma -I/bde/groups/bdl/bdlc -I/bde/groups/bdl/bdlt -I/bde/groups/bdl/bdls -I/bde/groups/bdl/bdldfp -I/bde/groups/bdl/bdlat -I/bde/groups/bdl/bdld -I/bde/groups/bdl/bdlcc -I/bde/groups/bdl/bdlmt -I/bde/groups/bdl/bdlpcre -I/bde/groups/bsl/bsls -I/bde/groups/bsl/bslscm -I/bde/groups/bsl/bsldoc -I/bde/groups/bsl/bslmf -I/bde/groups/bsl/bslma -I/bde/groups/bsl/bsltf -I/bde/groups/bsl/bslalg -I/bde/groups/bsl/bslh -I/bde/groups/bsl/bslstl -I/bde/groups/bsl/bsl+bslhdrs -I/bde/groups/bsl/bsl+stdhdrs -I/bde/groups/bsl/bslim -I/bde/groups/bsl/bslmt -I/bde/groups/bsl/bslx -I/bde/build/thirdparty -I/bde/thirdparty -I/bde/build/thirdparty/inteldfp/LIBRARY/src -I/bde/thirdparty/inteldfp/LIBRARY/src ../groups/bbl/bblb/bblb_schedulegenerationutil.cpp -c -o /bde/build/groups/bbl/bblb/bblb_schedulegenerationutil.cpp.1.o
"../groups/bbl/bblb/bblb_schedulegenerationutil.cpp", line 253: Error: The function "abs" must have a prototype.

Closing stale issues.