abd.h is not C++ friendly
A C++ compiler fails to compile abd_is_linear(), which is an inline function defined in abd.h, with the following error:
error: cannot initialize return object of type 'boolean_t' with an rvalue of type 'bool'
That happens because a bool can not be converted to an enum in C++.
That's a problem because abd.h can be visible through other header files that a C++ program that works with ZFS can include.
Updated by Electric Monk about 2 years ago
- % Done changed from 0 to 100
- Status changed from New to Closed
commit 5e2a074725cb7c16ea1c6554da11ab4d6b4e7aee Author: Andriy Gapon <avg@FreeBSD.org> Date: 2017-06-29T23:10:40.000Z 8416 abd.h is not C++ friendly Reviewed by: Igor Kozhukhov <firstname.lastname@example.org> Reviewed by: Dan Kimmel <email@example.com> Reviewed by: Alek Pinchuk <firstname.lastname@example.org> Approved by: Robert Mustacchi <email@example.com>