Skip to content

"Jump to Next Bound Occurrence" - Strange behavior with imported symbols #193

Open
@cfinegan

Description

@cfinegan

Consider the following 2 racket programs:

foo.rkt

#lang racket/base
(define foo "fooey")
(define bar 25)
(provide (all-defined-out))

bar.rkt

#lang racket/base
(require "foo.rkt")
(let ([x foo] [y bar])
  (printf "~v~n~v~n" foo bar))

If one navigates to to the foo reference on line 3 of bar.rkt and selects "jump to next bound occurrence", one would expect DrRacket to highlight the foo reference on line 4. What DrRacket actually does is highlight the reference to bar on line 3. It appears that DrRacket cannot distinguish between different symbols imported from the same file, and thus treats all symbols imported from a given file as being the equivalent for the purposes of code navigation.

This issue also applies to symbols imported from #lang statements. Using the same example above, if one navigates to the let reference on line 3 and selects "jump to next bound occurrence", DrRacket to will highlight the reference to printf on line 4.

Metadata

Metadata

Assignees

No one assigned

    Labels

    check-syntaxissues related to check-syntax, background expansion, drawing nifty arrows, etc.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions