r-lib / debugme

Easy and efficient debugging for R packages
https://r-lib.github.io/debugme/
Other
149 stars 10 forks source link

Custom formatters #18

Open krlmlr opened 7 years ago

krlmlr commented 7 years ago

Could be implemented with an argument to debugme(), like debugme::debugme(formatter = debugme:::handle_dynamic_code(.)) . Perhaps even with the default formatter = ..

gaborcsardi commented 7 years ago

Can you give an example what a formatter would do?

krlmlr commented 7 years ago

glue(), or e.g. print the deparsed expression along with its value.

gaborcsardi commented 7 years ago

Makes sense.

Btw. we can also just switch to glue by default.

krlmlr commented 7 years ago

glue won't give me auto-deparse ;-) Or will it? CC @jimhester

gaborcsardi commented 7 years ago

@krlmlr I mean, we can still have formatters, and independently, we could switch to glue formatting as the default. (And provide the current default formatter as an option.)