f18 icon indicating copy to clipboard operation
f18 copied to clipboard

Previous declaration pointer in error message points to erroneous declaration instead

Open klausler opened this issue 5 years ago • 0 comments

module m
  abstract interface
    subroutine foo
    end subroutine
  end interface
 contains
  subroutine foo
  end subroutine
end module

elicits

/tmp/bug.f90:7:14: error: 'foo' is already declared in this scoping unit
    subroutine foo
               ^^^
/tmp/bug.f90:7:14: Previous declaration of 'foo'
    subroutine foo
               ^^^

Both parts of the message point to the same declaration.

klausler avatar Sep 06 '19 22:09 klausler