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

Library provides implementation on Rust level instead of ink! level #5

Open
xgreenx opened this issue Jun 8, 2021 · 0 comments
Open
Assignees
Labels
usage-simplification Resolving of this issue will simplify the usage of the library

Comments

@xgreenx
Copy link
Contributor

xgreenx commented Jun 8, 2021

ink! doesn't allow to inject code of one contract into another. Because importing another contract without the feature "ink-as-dependency" will generate an entry point for the contract which will conflict with the entry points of the main contract.
Except that we all will have problems with metadata. Because of ink! can't generate metadata for imported crates. We described these issues in more detail here.

It requires us to provide a default implementation on the Rust level. It works and users can override default implementation with their logic but it creates some restrictions and inconveniences during usage of the library.

For example.

In the final vision, we want to have the implementation on the ink! level. But for now, we will develop and simplify usage on Rust level and parallelly will introduce something new to ink!.

This issue will track the migration process from Rust level to ink! when it will possible(after some changes in ink! we will evolve the library to use that changes).

@xgreenx xgreenx self-assigned this Jun 8, 2021
@xgreenx xgreenx added the usage-simplification Resolving of this issue will simplify the usage of the library label Jun 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
usage-simplification Resolving of this issue will simplify the usage of the library
Projects
None yet
Development

No branches or pull requests

1 participant