/dotty-macro-examples

Various tasks solved via metaprogramming in Dotty

Primary LanguageScala

Dotty Metaprogramming Examples

CI

This repo contains a bunch of examples of doing metaprogramming in Dotty.

Every folder is a separate example. Each example contains a README.md file with a description of what the example does.

To run an example:

  1. Clone and cd into the repo using git clone https://github.com/anatoliykmetyuk/dotty-macro-examples.git && cd dotty-macro-examples
  2. Use ./mill <example_name>.run command to run the example you are interested in. E.g. ./mill macroTypeclassDerivation.run runs macroTypeclassDerivation example.

Examples

https://github.com/anatoliykmetyuk/dotty-macro-examples/tree/master/abstractTypeclassBody