(1) Can anyone explain why the OP_CAT operation is disabled?
(2) Alternatively, can anyone explain why the OP_ADD (and other numeric operations) are 32-bit operations that throw an exception if the stack has a number that is larger than 32 bits?
https://github.com/libbitcoin/libbitcoin/blob/master/src/math/script_number.cpp#L91-L97
bool script_number::set_data(const data_chunk& data)
{
if (data.size() > max_script_number_size)
return false;
value_ = script_number_deserialize(data);
return true;
}
I ask because I would like to "mix" two values that are on the stack (eg. two hashes) and then take a hash of the result. The mixing can be accomplished with either a string concatenate or an addition operation. Any insight would be appreciated; if there are no serious reasons, I would like to consider drafting a BIP to change the behavior of one of the two operations (the most palatable one).
Thanks!
abhi