|
@ -195,7 +195,7 @@ enum class NodeType { |
|
|
namespace internal { |
|
|
namespace internal { |
|
|
|
|
|
|
|
|
//! Helper function for Node::CalcType.
|
|
|
//! Helper function for Node::CalcType.
|
|
|
Type CalcSimpleType(NodeType nodetype, Type x, Type y, Type z, const std::vector<Type>& sub_types, uint32_t k, size_t data_size, size_t n_subs, size_t n_keys); |
|
|
Type ComputeType(NodeType nodetype, Type x, Type y, Type z, const std::vector<Type>& sub_types, uint32_t k, size_t data_size, size_t n_subs, size_t n_keys); |
|
|
|
|
|
|
|
|
//! Helper function for Node::CalcScriptLen.
|
|
|
//! Helper function for Node::CalcScriptLen.
|
|
|
size_t ComputeScriptLen(NodeType nodetype, Type sub0typ, size_t subsize, uint32_t k, size_t n_subs, size_t n_keys); |
|
|
size_t ComputeScriptLen(NodeType nodetype, Type sub0typ, size_t subsize, uint32_t k, size_t n_subs, size_t n_keys); |
|
@ -332,7 +332,7 @@ private: |
|
|
Type y = subs.size() > 1 ? subs[1]->GetType() : ""_mst; |
|
|
Type y = subs.size() > 1 ? subs[1]->GetType() : ""_mst; |
|
|
Type z = subs.size() > 2 ? subs[2]->GetType() : ""_mst; |
|
|
Type z = subs.size() > 2 ? subs[2]->GetType() : ""_mst; |
|
|
|
|
|
|
|
|
return SanitizeType(CalcSimpleType(nodetype, x, y, z, sub_types, k, data.size(), subs.size(), keys.size())); |
|
|
return SanitizeType(ComputeType(nodetype, x, y, z, sub_types, k, data.size(), subs.size(), keys.size())); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
//! Internal code for ToScript.
|
|
|
//! Internal code for ToScript.
|
|
|