SnowflakePowered / snowflake

:snowflake: :video_game: Emulator Frontend and SDK
http://snowflakepowe.red
Mozilla Public License 2.0
245 stars 15 forks source link

Port configuration source generators to incremental #837

Open chyyran opened 2 years ago

chyyran commented 2 years ago

https://github.com/dotnet/roslyn/blob/main/docs/features/incremental-generators.md https://andrewlock.net/creating-a-source-generator-part-1-creating-an-incremental-source-generator/

If we can implement this at a property-level scope, we should endeavour to extract an API out so that orchestration plugins can use them and generate config.

chyyran commented 2 years ago

A big drawback + advantage is that configuration templates have to be compiled. This is similar to how Windows handles metadata for projections but makes it difficult to handle things like Cemu graphics packs that are updated via XML.

We need to provide primitives to generate a configuration template AST from aribtrary parsed ASt.