ergoplatform / ergoplatform/sigma-rust

iOS bindings ErgoBoxes.get uses DataInputPtr

Open
#576 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
78
Forks
63
Avg merge
22h 5m
Merged PRs (30d)
3

Description

Curious why a `DataInputPtr` is being used instead of an `ErgoBoxPtr`: https://github.com/ergoplatform/sigma-rust/blob/develop/bindings/ergo-lib-ios/Sources/ErgoLib/ErgoBox.swift#L514 when the C header has this as the method signature:

```
struct ReturnOption ergo_lib_ergo_boxes_get(ConstErgoBoxesPtr collection_ptr,
uintptr_t index,
ErgoBoxPtr *element_ptr_out);
```

Contributor guide

Open the contributing guide

Research direction

Start with bindings/ergo-lib-ios/Sources/ErgoLib/ErgoBox.swift at the referenced line and compare its DataInputPtr usage with the ergo_lib_ergo_boxes_get declaration in the C header. Confirm which pointer type the Swift binding should use, update the binding if it does not match, and validate the iOS bindings build.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust, swift
Domain
api, mobile-dev
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.