You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a project in which my cabal file specifies multiple libraries (since I'm using backpack) [1]. If I try to fire up an repl I have to select the correct target using haskell-session-change-target. That works well for selecting benchmarks or testsuites, however,
for each library stanza I just get a copy of "lib:" (so "lib:hgeometry-vector" in my particular case), and unfortunately that does not allow me to actually switch to the right library.
Browsing through the source a bit, I think the culprit is the haskell-cabal-enum-targets function in haskell-cabal.el. In particular, it seems that on line 520 it is indeed creating the "lib:" instances rather than picking whatever the right session name is. While I (think) I can read enough elisp to figure out where this went wrong, I'm not really fluent enough to easily change it to do the right thing. I guess we want to keep the current behavior for the unnamed global library, but use the proper section-name (=name of the sub-library) when the section has a name).
I have a project in which my cabal file specifies multiple libraries (since I'm using backpack) [1]. If I try to fire up an repl I have to select the correct target using haskell-session-change-target. That works well for selecting benchmarks or testsuites, however,
for each library stanza I just get a copy of "lib:" (so "lib:hgeometry-vector" in my particular case), and unfortunately that does not allow me to actually switch to the right library.
Browsing through the source a bit, I think the culprit is the haskell-cabal-enum-targets function in haskell-cabal.el. In particular, it seems that on line 520 it is indeed creating the "lib:" instances rather than picking whatever the right session name is. While I (think) I can read enough elisp to figure out where this went wrong, I'm not really fluent enough to easily change it to do the right thing. I guess we want to keep the current behavior for the unnamed global library, but use the proper section-name (=name of the sub-library) when the section has a name).
[1] the particular package in question is https://github.com/noinia/hgeometry/tree/hgeom-1/hgeometry-vector but I don't think it should matter.
The text was updated successfully, but these errors were encountered: