mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-29 16:40:38 +08:00
a43073a389
Some of the benchmark functions use the same name as other functions in the ceres namespace. For example Axpby defines both benchmark but also an utility function in eigen_vector_ops.h. It seems to confuse some compilers and leads to a compilation error rooting deeper into the benchmark header itself: it seems that the compiler can not deduct which of the instances of such functions to use. Wrapping the file into an anonymous namespace solves the problem. Alternative could be to use benchmark namespace to make thins more explicit, for example ceres::internal::benchmark. Tested on the following configuration: - macOS 15.4 - Xcode 16.3 - Apple M3 CPU - google-benchmark 1.9.2 installed via homebrew Change-Id: Id127015dd22de99c6c3da88e71f255736e0bed82