Skip to content

Conversation

samber
Copy link
Owner

@samber samber commented Jan 25, 2025

Adding some basic methods to mutable sub-package.

This PR introduces a new standard i would like to bring to this repo:

  • Map -> without index int
  • MapI -> with index int

I don't plan to make a breaking change to the main lo package in the short term.

Copy link

codecov bot commented Jan 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.35%. Comparing base (e5dba6f) to head (882fa2a).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #577      +/-   ##
==========================================
+ Coverage   94.31%   94.35%   +0.04%     
==========================================
  Files          18       18              
  Lines        3200     3224      +24     
==========================================
+ Hits         3018     3042      +24     
  Misses        170      170              
  Partials       12       12              
Flag Coverage Δ
unittests 94.35% <100.00%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@samber samber mentioned this pull request Jan 25, 2025
@Numichi
Copy link

Numichi commented Apr 24, 2025

I am happy because I have planned to implement zero allocation version. I found this PR before I make a PR. :) When do you plan to merge or continue?

Numichi@14b1d6a
I made Branchmarks and my results are:

cpu: Intel(R) Core(TM) i9-14900K

BenchmarkFilter
BenchmarkFilter/10
BenchmarkFilter/10-32 		54988611	21.11 ns/op		80 B/op		1 allocs/op
BenchmarkFilter/100
BenchmarkFilter/100-32         	 6737167	175.7 ns/op		896 B/op	1 allocs/op
BenchmarkFilter/1000
BenchmarkFilter/1000-32        	 740529		1706 ns/op		8192 B/op	1 allocs/op

BenchmarkFilterZ
BenchmarkFilterZ/10
BenchmarkFilterZ/10-32 		310881794	3.826 ns/op		0 B/op	       0 allocs/op
BenchmarkFilterZ/100
BenchmarkFilterZ/100-32        31369514		38.69 ns/op		0 B/op	       0 allocs/op
BenchmarkFilterZ/1000
BenchmarkFilterZ/1000-32       3697268		323.6 ns/op		0 B/op	       0 allocs/op

@samber samber merged commit c7a67ca into master Apr 26, 2025
20 checks passed
oswaldom-code pushed a commit to oswaldom-code/lo that referenced this pull request Apr 28, 2025
* feat(mutable): adding Map, MapI, Filter, FilterI

* Update README.md

* doc: add doc and examples for lom.Filter

* oops
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