Skip to content

Conversation

@kstenerud
Copy link
Contributor

To get around duplicate symbol linker errors in #255

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR extracts FFI (Foreign Function Interface) functionality from the bd-bonjson crate into a separate bd-bonjson-ffi crate to resolve duplicate symbol linker errors.

  • Moves all FFI-related code from bd-bonjson to a new bd-bonjson-ffi crate
  • Updates the Writer API to use a constructor pattern instead of direct struct initialization
  • Adjusts test files and build configurations to reference the new crate structure

Reviewed Changes

Copilot reviewed 11 out of 13 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
bd-bonjson/src/lib.rs Removes ffi module export
bd-bonjson/src/writer.rs Adds public constructor method for Writer
bd-bonjson/src/writer_test.rs Updates test to use new Writer constructor
bd-bonjson-ffi/src/lib.rs New FFI crate with WriterBufWriterFile wrapper and C bindings
bd-bonjson-ffi/include/bd-bonjson/ffi.h C header file for FFI functions
bd-bonjson-ffi/Cargo.toml New crate configuration
bd-bonjson-ffi/build.rs Build script for generating C bindings
bd-bonjson-tests/src/ffi_tests.rs Updates import to use new FFI crate
bd-bonjson-tests/Cargo.toml Adds dependency on new FFI crate
bd-bonjson-tests/build.rs Updates build dependency path
Cargo.toml Adds new crate to workspace

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@kstenerud kstenerud force-pushed the karl/move-bonjson-ffi branch from a3c8471 to 63e1b6d Compare September 22, 2025 17:23
@kstenerud kstenerud requested a review from Copilot September 22, 2025 17:23
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 11 out of 13 changed files in this pull request and generated 2 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@kstenerud kstenerud force-pushed the karl/move-bonjson-ffi branch from 63e1b6d to 347e51d Compare September 22, 2025 17:30
@kstenerud kstenerud requested a review from Copilot September 22, 2025 17:30
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 11 out of 13 changed files in this pull request and generated 2 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@kstenerud kstenerud force-pushed the karl/move-bonjson-ffi branch from 347e51d to 09a1758 Compare September 22, 2025 17:34
@kstenerud kstenerud requested a review from Copilot September 22, 2025 17:35
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 11 out of 13 changed files in this pull request and generated 1 comment.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@kstenerud kstenerud force-pushed the karl/move-bonjson-ffi branch from 09a1758 to 812f7e7 Compare September 22, 2025 17:39
@kstenerud kstenerud merged commit 7ee610d into main Sep 23, 2025
6 checks passed
@kstenerud kstenerud deleted the karl/move-bonjson-ffi branch September 23, 2025 14:50
@github-actions github-actions bot locked and limited conversation to collaborators Sep 23, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants