kenbot / goggles

Pleasant, yet principled Scala optics DSL
MIT License
195 stars 7 forks source link

Can uninferred types of interpolated args be repaired? #19

Open kenbot opened 7 years ago

kenbot commented 7 years ago

Within the macro, type information flows from left to right throughout, allowing type inference to finish the job in the generated code.

However, interpolated values are typechecked before the macro runs. Some interpolated optics that have type parameters (ie monocle.function.At.at) crap out with [Nothing,Nothing], because they don't have the information. Is it possible within the macro to redact the type parameters, inserting the information that we already know?