scala-macro-paradise Questions

2

Solved

The following is a quote from Macros: the Plan for Scala 3 from more than 3 years ago: For instance, one will be able to define a macro annotation @json that adds a JSON serializer to a type. Any...
Enharmonic asked 31/5, 2021 at 9:13

1

I just updated to scala meta 2.0.0-M1 and with the latest scala 2.12.3 and now macros no longer compile. The only change i made was to change the meta version from 1.8.0 to 2.0.0-M1. ERROR: new-st...
Uredium asked 2/8, 2017 at 20:8

0

I'd like to write a macro which enriches case classes. When I declare my case class like this: case class User(int id, @tagged name) I want to be able to inject some stuff into the Tree of this ...
Cirilo asked 22/3, 2016 at 20:45

1

Solved

I want to generate aliases of methods using annotation macros in Scala 2.11+. I am not even sure that is even possible. If yes, how? Example - Given this below, I want the annotation macros to exp...
Cinnamon asked 22/10, 2015 at 11:2

1

Solved

I am curious about this statement: Error:(3, 18) ...another possibility is that you try to use macro annotation in the same compilation run that defines it) I tried googling and found this: ...
Pineal asked 15/8, 2015 at 5:2

3

I would like to extract from a given Scala project, the call graph of all methods which are part of the project's own source. As I understand, the presentation compiler doesn't enable that, and it...
Rossner asked 22/4, 2015 at 0:15

3

Solved

I want to do something like this: def assuming[A](condition: => Boolean)(f: => A): A = { require(condition, /* print source-code of condition */) f } Sample usage: def fib(n: Int) = n m...
1

© 2022 - 2024 — McMap. All rights reserved.