`groupBy` has unexpected `l` argument for `a -> a -> Boolean` predicate

Aperta
#229 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

  • #230 di @JordanMartinez — chiusa senza merge

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Ambito
backend

Direzione di ricerca

Start with the linked try.purescript.org example and inspect the groupBy implementation and its tests to trace how the predicate arguments are chosen. The report expects adjacent pairs (0, 1) and (1, 2) for [0, 1, 2]; determine whether the behavior is unintended, then add a regression test and confirm it passes if a change is warranted.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

See https://try.purescript.org/?gist=26968458c1261226b33e574128ba9aae

For a given array like [0, 1, 2], I expect the l and r arguments to be

  • first run: 0 and 1
  • second run: 1 and 2

However, in the second run, l is 0 rather than 1.

I'd argue that the behavior here is unexpected.

Lingua principale
PureScript
Stelle
58
Fork
70
Merge medio
2g 22h
PR unite (30g)
1

Preparare l'ambiente

  • Nessun Dockerfile né file Docker Compose
  • Ha un modello di pull request
  • Nessuna guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di purescript/purescript-arrays

Tutte le issue di purescript/purescript-arrays

Issue simili

Altre issue su Backend & API Design

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.