Closed stacycurl closed 6 years ago
Do you mean different domains would want to quote in different ways ?
I probably won't need it, instead I'm going to create a new project to define a 'Homoiconic' type class.
val someHardToRecreateValue: Blah = ... val asCode: String = Homoiconic[Blah].show(someHardToRecreateValue)
assert(eval(asCode) == someHardToRecreateValue)
This is so I can paste the value of 'asCode' into some unit test.
implicit val homoiconicString: Homoiconic[String] = new Homoiconic[String] { def show(value: String): String = "\"" + value + "\"" }
// shapeless voodoo to create instances for case classes using structural recursion to leaves.
On 10 April 2015 at 17:48, Sam Halliday notifications@github.com wrote:
isn't this going to be heavily domain specific?
— Reply to this email directly or view it on GitHub https://github.com/stacycurl/pimpathon/issues/206#issuecomment-91617500.
Stacy
isn't this going to be heavily domain specific?