BUG: can't hook up toDump extension method with F# program
per https://www.linqpad.net/CustomizingDump.aspx
I should be able to make it customize the dump of a `Newtonsoft.Json.Linq.JProperty`
However, no matter what I try, (trying not to use MyExtensions since it is C# only) it won't hook up
http://share.linqpad.net/jhwfi2.linq
produces just the value, not the name and value, nor do any of the print statements get hit.
I should be able to make it customize the dump of a `Newtonsoft.Json.Linq.JProperty`
However, no matter what I try, (trying not to use MyExtensions since it is C# only) it won't hook up
http://share.linqpad.net/jhwfi2.linq
produces just the value, not the name and value, nor do any of the print statements get hit.
Comments
I've taken a look at whether it would easy to allow My Extensions to be written in F#, but unfortunately, there's a fair bit of work involved. So the only option right now is to write the ToDump in C#.
@JoeAlbahari is this still entirely unavailable in F# to localized types?
ToDump is recognized in two places the moment:
LINQPad does not look for ToDump methods defined via F# type extensions. It could end up being quite a lot of work to implement this in LINQPad reliably. FWIW, there's no C# solution for this either: right now, a static ToDump method is recognized only in My Extensions and not in individual queries.