bt2: create_value(): check `numbers` and `collections.abc` types
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Fri, 28 Jun 2019 05:16:21 +0000 (01:16 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 18 Jul 2019 15:53:33 +0000 (11:53 -0400)
commit3917b7948e72b326840f702f2392a6259810b124
treee461769db8fa794c735cfb51e3d1f6c3b766bf4d
parent1b742cb682d21c49c182036f2f0cd4dfb34cb72a
bt2: create_value(): check `numbers` and `collections.abc` types

This is just like what's done within _NumericValue._extract_value(),
_IntegerValue._value_to_int(), RealValue._value_to_float(),
StringValue._value_to_str(), ArrayValue.__eq__(), and MapValue.__eq__().

It is more versatile than checking for the specific built-in types.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Change-Id: I93902e58b6adf3f9cd5c03c7c422148d577b5f0f
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1571
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Reviewed-by: Simon Marchi <simon.marchi@efficios.com>
src/bindings/python/bt2/bt2/value.py
This page took 0.033869 seconds and 4 git commands to generate.