Skip to content

Conversation

@trinistr
Copy link
Contributor

@trinistr trinistr commented Nov 20, 2025

Continuing from #1297

  • Added a spec for .map. It has a lot of edge cases.
  • Added specs for .for and .string. Not much to say about these, they behave according to documentation and don't have complicated arguments.
  • Added more cases for #initialize (.new).
  • Removed most cases for predicate methods, leaving just a few representative examples, as flags are checked in constructor specs.

More weird stuff:

@trinistr trinistr force-pushed the add-io-buffer-constructors-specs branch 5 times, most recently from fb299b4 to 60c35d9 Compare November 20, 2025 18:36
@eregon
Copy link
Member

eregon commented Nov 20, 2025

@ioquatix Could you review this maybe?

@trinistr
Copy link
Contributor Author

@ioquatix Could you review this maybe?

This is still a very early draft, but that offset parameter made me create an issue and a PR to ruby directly, so, yeah 🥹 Reviewing the PR with fixes for the method is probably more useful currently.

@trinistr trinistr force-pushed the add-io-buffer-constructors-specs branch 2 times, most recently from c38d813 to 903d51d Compare November 29, 2025 08:46
@ioquatix ioquatix force-pushed the add-io-buffer-constructors-specs branch from 903d51d to fc60523 Compare December 6, 2025 21:09
@trinistr trinistr force-pushed the add-io-buffer-constructors-specs branch 2 times, most recently from 6a2a7d3 to afd7846 Compare December 16, 2025 15:25
.map has a lot of edge cases that are practically undefined behavior and may cause syscall error or crashes.
@trinistr trinistr force-pushed the add-io-buffer-constructors-specs branch from afd7846 to 9ebc319 Compare December 17, 2025 14:21
Also simplify specs for predicate methods, as flags are mostly set on buffer creation and tested accordingly.
@trinistr trinistr force-pushed the add-io-buffer-constructors-specs branch from 9ebc319 to bc2f82c Compare December 17, 2025 14:26
@trinistr trinistr marked this pull request as ready for review December 17, 2025 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants