qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Toralf Lund (JIRA)" <j...@apache.org>
Subject [jira] [Created] (QPID-6669) Integer variants not convertible to double
Date Fri, 31 Jul 2015 06:44:04 GMT
Toralf Lund created QPID-6669:
---------------------------------

             Summary: Integer variants not convertible to double
                 Key: QPID-6669
                 URL: https://issues.apache.org/jira/browse/QPID-6669
             Project: Qpid
          Issue Type: Bug
          Components: C++ Client
            Reporter: Toralf Lund


QPid::Variants, and by extension message properties, of "integer" types cannot be converted
to floating-point, even thought there is no obvious reason why this shouldn't be possible.

I found out about this when using a construct of the form
{code}
uint32 inValue=...;
message.setProperty("property", inValue);
{code}
in a message sender, and 
{code}
double value=message.getProperties()["property"];
{code}
at the receiving end. This lead to an _InvalidConversion_ exception, with the message
{quote}
Cannot convert from uint32 to double (qpid/types/Variant.cpp:488)
{quote}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


Mime
View raw message