Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Does PER 3.0 has an issue with "very complex" example in section 2.5?

Aperta
#131 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
1/5
Tempo stimato
1-3 ore
Idoneità per principianti
35/100
Tipo di issue
Documentazione
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
php
Ambito
documentation

Direzione di ricerca

Compare the “very complex” example in section 2.5 with the multiline argument formatting described in section 4.5. Confirm the intended formatting with the surrounding examples and discussion; done means section 2.5 uses the agreed consistent example.

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

Descrizione

Hey, everyone!

Just noticed the way how "very complex" example is being put in 2.5:

Image

I would think it is a little bit illogical, because it violates of how we're formatting multiline arguments for functions, see 4.5:

Image

Another example is the same 2.5 section:

function somethingWithReflection(
    \ReflectionObject
    |\ReflectionClass
    |\ReflectionMethod
    |\ReflectionParameter
    |\ReflectionProperty $reflect
): object|null {
        // ...
}

That's why I suspect it is just a typo, and correct example for "veryComplex" would be:

function veryComplex(
    array
    |(ArrayAccess&Traversable)
    |(Traversable&Countable) $input
): ArrayAccess&Traversable {
    // ...
}

WDYT about it?

Feel free to ask me to create PR if my assumptions are correct 🙌

Best regards

Lingua principale
Nessun dato sulla lingua
Stelle
284
Fork
27
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

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 php-fig/per-coding-style

Tutte le issue di php-fig/per-coding-style

Issue simili

Altre issue su Documentation

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.