[Rd] sys.call() 's srcref doesn't match the language

brodie gaslam brod|e@g@@|@m @end|ng |rom y@hoo@com
Thu Sep 3 01:44:25 CEST 2020


>On Wednesday, September 2, 2020, 6:19:20 PM EDT, Lionel Henry <lionel using rstudio.com> wrote:
>
>Hello,
>
>The source references are useful for debugging tools because they
>allow linking to call sites in the source files.
>
>I agree the output can be confusing. Perhaps this could be fixed by
>tweaking the print method for calls. If the deparsed call doesn't
>match the srcref, both could be displayed along with file:line:column.
>
>```
>#> f()
>#> <srcref:file.R:2:3>
>#> 1 + f()
>```
>
>Best,
>Lionel

Why print the mismatched srcref at all?  I find that confusing.
Just omit the srcref from display. Debugging tools can
still retrieve it and use the information, presumably.

Best,

Brodie.



More information about the R-devel mailing list