fortran-lang / fortls

fortls - Fortran Language Server
https://fortls.fortran-lang.org/
MIT License
258 stars 41 forks source link

Incomplete hover of parameters variables #284

Closed gbogopolsky closed 6 months ago

gbogopolsky commented 1 year ago

Describe the bug When hovering over a variable that was defined as a computed parameter, only the first member of the computation shows up

To Reproduce Define a computed parameter, use it in the code and hover over it. If there is a space or "/" in the parameter definition, anything after will not show up.

real(8), parameter :: three = 1.0d0*3.0d0
real(8), parameter :: six = 2.0d0 * 3.0d0
real(8), parameter :: one = 1.0d0
real(8), parameter :: sixth = one / six
real(8), parameter :: third = one/three

On Hovering, one gets the following:

image image image image image

Except when there is a "*" without spaces, the second term of the computed parameter is always missing.

Expected behavior I would expect the whole line to show up, until an endline character or the start of a comment.

Setup information (please complete the following information):

folk85 commented 1 year ago

I suggest the solution of this bug. Add several tests. But pytest -v failed in one test test/test_interface.py::test_version_update_pypi.