massivebird / arcconfig

A library for interacting with my video game archive
https://crates.io/crates/arcconfig
GNU General Public License v3.0
0 stars 0 forks source link

Add an `extract_property` macro #15

Closed massivebird closed 9 months ago

massivebird commented 9 months ago

I can nearly create an extract_property(&str) -> &str closure — except that the color property stands out as being parsed as a vector rather than as a string.

Also, I can't figure out how to pass in an "iterator-chain" function as a closure parameter (such as as_str or as_vec).

A macro should be able to do this, though! That'd be so neat.

Probably slow, but neat.