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

Evaluate lazy-ghost initialization for ReflectionConstructorInvocation::proceed()

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

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
22/100
Tipo di issue
Refactoring
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
php
Ambito
backend

Direzione di ricerca

The code in question is src/Aop/Framework/ReflectionConstructorInvocation.php around lines 65-77, where newInstanceWithoutConstructor() plus getConstructor()->invoke() currently builds the instance. Read the lazy-object work from #612 in Container and CachedAspectLoader first, then the gap noted in docs/php84-limitations.md, and reproduce the classes newLazyGhost() rejects (internal, property-less). Done means a written decision: a behavior-preserving patch validated against the existing AOP tests, or a documented rationale for keeping the explicit sequence.

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

Descrizione

Enhancement PHP8.4

Summary

Follow-up to #606 (closed by #612, which implemented native lazy objects in Container and CachedAspectLoader). Item 3 of that issue — rewriting ReflectionConstructorInvocation::proceed() (src/Aop/Framework/ReflectionConstructorInvocation.php ~65-77, currently newInstanceWithoutConstructor() + manual getConstructor()?->invoke(...)) via the PHP 8.4 lazy-ghost initializer sequence — was deliberately skipped and needs its own ticket so it isn't lost.

Why it was skipped in #612

  • A lazy ghost there would either need immediate forced initialization (no gain over the explicit sequence) or would defer constructor side effects, changing observable behavior around getThis() and Before advices.
  • newLazyGhost() rejects classes the current sequence handles fine (internal classes, property-less classes).

What this ticket asks

Design a behavior-preserving adoption (or conclude and document that the explicit sequence is the right mechanism). If adopted, it is also the natural groundwork for the gap noted in docs/php84-limitations.md: no join point exists today for the moment a lazy proxy materializes.

Lingua principale
PHP
Stelle
1.7k
Fork
166
Merge medio
9h 50m
PR unite (30g)
30

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 goaop/framework

Tutte le issue di goaop/framework

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.