Parse error for Haskell sections
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
Riproduci l’esempio in haskell-mode e inizia leggendo haskell-forward-sexp, haskell-backward-sexp e l’interazione con plain backward-sexp in corrispondenza della d di div. Il lavoro è completato quando C-M-u naviga correttamente da ogni posizione all’interno della sezione Haskell senza segnalare un errore di scansione per parentesi non bilanciate.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Consider the program:
main = print $ (`div` 2) 3
If you put the cursor inside the brackets anywhere except on the first back-tick character and hit C-M-u (backward-up-list) the cursor is placed at the beginning of the current buffer and a scan error is echoed to the *Messages* buffer:
up-list: Scan error: "Unbalanced parentheses", 1, 1
I tried to debug this, but I'm not great with lisp. I think it has to do with the fact that "plain" backward-sexp and haskell-backward-sexp don't agree on where to go when cursor is on the d in div. There is a comment in haskell-forward-sexp saying that:
Navigate backwards using plain `backward-sexp', assume that it skipped over at least one Haskell expression
If I switch to fundamental-mode I can see that this assumption doesn't hold if you call backward-sexp with the cursor on the d in div.
I would love to provide the patch, but I'm afraid I need help digging to locate the bug.
The bug is present in at least versions 20231115.1812 and 20240116.1718.
- Lingua principale
- Emacs Lisp
- Stelle
- 1.4k
- Fork
- 357
- Merge medio
- 7h 50m
- PR unite (30g)
- 1
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di haskell/haskell-mode
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
haskell/haskell-mode#1889 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 65/100
haskell/haskell-mode#1522 ·
-
haskell-indentation: identifier named `signature` breaks indentation for the rest of the declarationForse già presa @PerryLink l’ha presa 48 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 78/100
haskell/haskell-mode#1895 ·
-
.hsc/CPP Can't find headers.Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 35/100
haskell/haskell-mode#1892 ·
-
Need help with haskell-modeAperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
haskell/haskell-mode#1890 ·
Tutte le issue di haskell/haskell-mode
Issue simili
-
area: middleware enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
rohitgollarahalli/mcpx#45 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
facebookresearch/atlas-lean#20218 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100