cpp-common/bt2: use classes from `cpp-common/exc.hpp`
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Mon, 30 May 2022 11:46:26 +0000 (07:46 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Mon, 11 Sep 2023 15:24:02 +0000 (11:24 -0400)
commit39278ebc70d57de534466c533d6c543a318dfdac
treea2f4e4b0943425d3e60c5556545e15363eb5d970
parentf1380b364342d937addeef1d66ad36fe777d46ec
cpp-common/bt2: use classes from `cpp-common/exc.hpp`

This patch:

* Renames `lib-error.hpp` to `exc.hpp` as this could contain non-error
  exceptions in the future.

* Changes `bt2::Error`, `bt2::MemoryError`, and `bt2::OverflowError` to
  be aliases of `bt2_common::Error`, `bt2_common::MemoryError`, and
  `bt2_common::OverflowError`.

  This makes it possible for some code to catch only the common
  `bt2_common` errors to handle both library and user/internal
  exceptions.

  Note that those exceptions don't carry much information themselves;
  they're usually just a signal that an exception occurred, while the
  details are part of the libbabeltrace2 error of the current thread.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Change-Id: I5bc1d39c8d978c21604614c68012509edc1776d5
Reviewed-on: https://review.lttng.org/c/babeltrace/+/8176
Reviewed-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/10824
Tested-by: jenkins <jenkins@lttng.org>
src/cpp-common/bt2/clock-class.hpp
src/cpp-common/bt2/clock-snapshot.hpp
src/cpp-common/bt2/exc.hpp [new file with mode: 0644]
src/cpp-common/bt2/field-class.hpp
src/cpp-common/bt2/field.hpp
src/cpp-common/bt2/integer-range-set.hpp
src/cpp-common/bt2/internal/utils.hpp
src/cpp-common/bt2/lib-error.hpp [deleted file]
src/cpp-common/bt2/message.hpp
src/cpp-common/bt2/trace-ir.hpp
src/cpp-common/bt2/value.hpp
This page took 0.025594 seconds and 4 git commands to generate.