Skip to content

[Type] Add streaming deserialization for vector<std::string>#6106

Open
alxbilger wants to merge 1 commit intosofa-framework:masterfrom
alxbilger:vectorstringdeserialize
Open

[Type] Add streaming deserialization for vector<std::string>#6106
alxbilger wants to merge 1 commit intosofa-framework:masterfrom
alxbilger:vectorstringdeserialize

Conversation

@alxbilger
Copy link
Copy Markdown
Contributor

Issue: the read/write method for sofa::type::vector<std::string> are not symmetric.

Implements read functionality for vector<std::string>, supporting both bracketed, quoted formats (e.g., ["a", "b"]) and plain whitespace-separated tokens as a fallback. Includes robust error checking and failure reporting via std::cerr.

Also adds comprehensive unit tests covering various input formats and expected parsing behaviors for string vectors.


By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).


Reviewers will merge this pull-request only if

  • it builds with SUCCESS for all platforms on the CI.
  • it does not generate new warnings.
  • it does not generate new unit test failures.
  • it does not generate new scene test failures.
  • it does not break API compatibility.
  • it is more than 1 week old (or has fast-merge label).

@alxbilger alxbilger added pr: status to review To notify reviewers to review this pull-request pr: clean Cleaning the code labels May 5, 2026
Implements `read` functionality for `vector<std::string>`, supporting both bracketed, quoted formats (e.g., `["a", "b"]`) and plain whitespace-separated tokens as a fallback. Includes robust error checking and failure reporting via `std::cerr`.

Also adds comprehensive unit tests covering various input formats and expected parsing behaviors for string vectors.
@fredroy fredroy force-pushed the vectorstringdeserialize branch from ee2d05c to b019766 Compare May 5, 2026 22:12
@alxbilger alxbilger added the pr: AI-aided Label notifying the reviewers that part or all of the PR has been generated with the help of an AI label May 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: AI-aided Label notifying the reviewers that part or all of the PR has been generated with the help of an AI pr: clean Cleaning the code pr: status to review To notify reviewers to review this pull-request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants