Skip to content

Introducing Older/After Translation functionality #435

@SarcasticNastik

Description

@SarcasticNastik

In the same way as #434

Up until now, we had support for key translation (and upcoming hash translations) which provide similar analysis guarantees as before. Doing the same for older/after does change things, and some of the miniscripts analysis we are able to do might not be possible. For example:- script_size requires us knowing the serialized length of the older/after time integer parameter.
Besides associating the Older type for a generic MiniscriptKey to u32, there are following possibilities we can try to offer:

  1. All the miniscripts are analyzable and we always keep the type Older -> u32 association.
  2. We introduce Analyzable trait, and use it to store the association as above for proper analysis. (More involving to implement, but gives us more flexibility working with generic miniscripts)
  3. We migrate the analysis requiring older/after parameter u32 to only support MiniscriptKey + ToPublicKey, but we might lose some flexibility here. (easier to implement)
    I'm confused here and would like to know others' view on the same.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions