Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Follow-up for light client extraction PR #9

Open
8 tasks
hu55a1n1 opened this issue Aug 26, 2022 · 0 comments
Open
8 tasks

Follow-up for light client extraction PR #9

hu55a1n1 opened this issue Aug 26, 2022 · 0 comments
Labels
O: new-feature Objective: aims to add new feature

Comments

@hu55a1n1
Copy link
Contributor

Summary

This is the follow-up issue for PR informalsystems/hermes#2483.

  • Use the downcast-rs crate - This will allow us to remove the AsAny and AsAnyMut code we currently have. It also provides a way for going from boxed trait objects to boxed concrete types without cloning, something that isn't possible with the current API. eg. Box<dyn ClientState> -> Box<TmClientState>.
  • Use macros for ErasedPartialEq defs and impls. Ideally all erased traits and their blanket impls must follow the convention that most well-known dyn-* rust crates use, for e.g. dyn-clone ->
    /// Define trait with supertrait
    trait MyTrait: DynClone {
        /* ... */
    }
    
    /// Use proc-macro to provide default impl
    dyn_clone::clone_trait_object!(MyTrait);
  • Separate trait for into_box(). (downcast-rs might already have a solution for this)

For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate milestone (priority) applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@hu55a1n1 hu55a1n1 transferred this issue from informalsystems/hermes Sep 28, 2022
@plafer plafer added the O: new-feature Objective: aims to add new feature label Dec 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O: new-feature Objective: aims to add new feature
Projects
None yet
Development

No branches or pull requests

2 participants