On Thu Oct 9 19:37:42 2025 +0000, Jacek Caban wrote:
If attributes require a special code path, they might as well avoid the shared implementation entirely. However, I don’t see why that’s necessary. Attributes already support indexed access through `get_dispid`, and we could use the same approach here. It’s unfortunate that this is slower than relative iteration for legacy attributes, but that’s a broader issue, and I don’t think we should change the shared code for it. Also, we could add these new helpers to `dispex_static_data_vtbl_t` instead of introducing a new vtbl type. Eventually, that could also be used to share indexed `get_dispid`/`invoke` logic.
Yeah, but are you sure it's a good idea for attributes? Since that's implemented on Next in the enumerator, it becomes basically `O(N^2)` if it's enumerated (as opposed to random access which is just one iteration in principle, so `get_dispid` isn't nearly as bad).