diff options
author | Jan Arve Saether <jan-arve.saether@theqtcompany.com> | 2015-04-10 11:28:16 +0200 |
---|---|---|
committer | Jan Arve Sæther <jan-arve.saether@theqtcompany.com> | 2015-04-15 10:58:39 +0000 |
commit | 81cc473cef1bb24a87382b93802cfc6e31eeb3c6 (patch) | |
tree | 389be41367292c129b82dd8de9bdcb3db8b1dfde /src | |
parent | 5199cce73762771f593f12abbe326f8086142c0e (diff) | |
download | qtxmlpatterns-81cc473cef1bb24a87382b93802cfc6e31eeb3c6.tar.gz |
Skip op-numeric-unary-minus-1 testcase because it crashes.
It seems to require a larger refactoring in order to solve this, so
we skip this for now in order for us to be able to run the remaining
tests in CI.
Change-Id: I2ae4860a92cdb7fb88ca89c4dd1f047bacbaaf9e
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/xmlpatterns/expr/qunaryexpression.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/xmlpatterns/expr/qunaryexpression.cpp b/src/xmlpatterns/expr/qunaryexpression.cpp index 1c4524e..f99096b 100644 --- a/src/xmlpatterns/expr/qunaryexpression.cpp +++ b/src/xmlpatterns/expr/qunaryexpression.cpp @@ -59,7 +59,10 @@ Item UnaryExpression::evaluateSingleton(const DynamicContext::Ptr &context) cons { const Item item(m_operand2->evaluateSingleton(context)); - if(item) + if (item) + // If the item is an untypedAtomic (or atomicString), the cast to Numeric will + // return a garbage object and will most likely cause a crash. + // There is simply no way to static cast from an instance of AtomicString to a Number. return item.as<Numeric>()->toNegated(); else return Item(); |