Add "explicit" qualifier to Optional -> bool conversion method
authorRob Hughes <robert.hughes@arm.com>
Wed, 11 Sep 2019 08:51:13 +0000 (09:51 +0100)
committerRob Hughes <robert.hughes@arm.com>
Thu, 12 Sep 2019 13:46:34 +0000 (13:46 +0000)
commit1e0466c4ab26e82abed7f8f263dfe6a2a543cc1a
tree6fa752c054f863e38e364d09e91cc8913f72f709
parent9bab49686a091d61fd06a05bbf7286f559fdae3d
Add "explicit" qualifier to Optional -> bool conversion method

This prevents unintended conversions that could lead to incorrect code
compiling, e.g. Optional<a> == Optional<b>

Also add comparison (==) operator to compare two Optionals.

Update unit tests accordingly

Change-Id: I6f975de7e666ba1ffe16c3ab50643116c6317135
Signed-off-by: Rob Hughes <robert.hughes@arm.com>
include/armnn/Optional.hpp
src/armnn/test/OptionalTest.cpp