Been playing with macro for a while, but I am having a hard time figuring out how to write a macro that generates a code based on a content that is only available dynamically.
Say I retrieved the flowers from some API or database
let flowers = ["Rose","Tullip", "Orchid"];
and I want to create a macro that generates the code like this.
enum Flower{
Rose,
Tullip,
Orchid
}
What's the easiest way to do this?