Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Re-export publicly used types #106

@juchiast

Description

@juchiast

Crates splitting is a bit too extreme at the moment IMO, some types are required when using a crate, but they are defined elsewhere and has to be imported separately, this will cause problem when you have more major versions in the future, because the crates need to be compatible with each other.

Some examples:

  • solana-signer: Pubkey and Signature types is in Signer trait definition
  • solana-keypair: should add a new signer feature flag to gate impl Signer, and re-export needed type when the feature is activated.
  • solana-client: CommitmentConfig, Signature, Pubkey
    There are probably many more.

There is also ergonomic problems, e.g. if my code need to sign a message, I have to import 4 crates: keypair, pubkey, signature, signer;

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