-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Automate Rust to C++ FFI #4220
base: master
Are you sure you want to change the base?
Automate Rust to C++ FFI #4220
Conversation
Yaml file generated: class: TWTONAddressConverter
static_functions:
- name: ToBoc
rust_name: tw_ton_address_converter_to_boc
args:
- name: address
ty: '* const TWString'
return_type: '* mut TWString'
- name: FromBoc
rust_name: tw_ton_address_converter_from_boc
args:
- name: boc
ty: '* const TWString'
return_type: '* mut TWString'
- name: ToUserFriendly
rust_name: tw_ton_address_converter_to_user_friendly
args:
- name: address
ty: '* const TWString'
- name: bounceable
ty: bool
- name: testnet
ty: bool
return_type: '* mut TWString' |
Binary size comparison➡️ aarch64-apple-ios: - 12.77 MB
+ 12.78 MB +8 KB ➡️ aarch64-apple-ios-sim: - 12.77 MB
+ 12.78 MB +8 KB ➡️ aarch64-linux-android: - 16.56 MB
+ 16.57 MB +12 KB ➡️ armv7-linux-androideabi: - 14.00 MB
+ 14.01 MB +11 KB ➡️ wasm32-unknown-emscripten: - 11.72 MB
+ 11.73 MB +8 KB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @gupnik, macros part looks good, please consider codegen-v2/cpp module refactoring.
We should try to have code duplicate as minimum as possible
…ore into gupnik/cpp-code-gen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks much better! Only small improvements please
Description
This PR intends to automate the rust to cpp conversion. It is broken down into the following tasks
How to test
Ensuring that the current builds and tests are executed correctly
Types of changes
New feature (non-breaking change which adds functionality)
Checklist
If you're adding a new blockchain