emilk / emilk/egui

FR IdTypeMap: iterate over entries by type

Open
#8,323 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
30.6k
Forks
2.1k
Avg merge
1d 9h
Merged PRs (30d)
72

Description

There is already a function [`remove_by_type`](https://docs.rs/egui/0.35.0/egui/util/id_type_map/struct.IdTypeMap.html#method.remove_by_type) to remove all entries of a given type.
I request a function `iter_by_type` to obtain an iterator over all entries of type T.
EDIT: bad link

Contributor guide

Open the contributing guide

Research direction

Start with the IdTypeMap documentation and its existing remove_by_type entry point linked in the issue, then locate the implementation and related tests. Add an iter_by_type API that yields all entries of type T, and verify the iterator behavior with focused tests for matching and non-matching types.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.