golang.org/x/tools/gopls@v0.15.3/internal/test/marker/testdata/rename/issue61294.txt (about)

     1  
     2  This test renames a parameter var whose name is the same as a
     3  package-level var, which revealed a bug in isLocal.
     4  
     5  This is a regression test for issue #61294.
     6  
     7  -- go.mod --
     8  module example.com
     9  go 1.18
    10  
    11  -- a/a.go --
    12  package a
    13  
    14  func One()
    15  
    16  func Two(One int) //@rename("One", "Three", OneToThree)
    17  
    18  -- b/b.go --
    19  package b
    20  
    21  import _ "example.com/a"
    22  
    23  -- @OneToThree/a/a.go --
    24  @@ -5 +5 @@
    25  -func Two(One int) //@rename("One", "Three", OneToThree)
    26  +func Two(Three int) //@rename("One", "Three", OneToThree)