PInterval
can have more efficient representation for more complicated manipulation
#796
Labels
enhancement
New feature or request
PInterval
as it is provided by the ledger api is very inefficient for complicated operations on interval.pcontains
as it is is well optimized and having intermediary representation will actually do harm on its performance by introducing extra conversion from ledger type to intermediary type. However, if script requires multiple and more complicated operations(like a series of checking interval union, intersection, etc, etc) on interval, it would be cheaper to convert ledger interval into intermediary interval, do multiple operation on converted interval, and convert back to ledger interval.Below is possible idea for more efficient intermediary interval proposed by @kozross.
Because this optimization is very specifically targeted to scripts that require complicated interval operations, this issue will only be implemented upon request if any project need this.
The text was updated successfully, but these errors were encountered: