|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-03-22 18:35 UTC] derick@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 19 21:00:01 2025 UTC |
Description: ------------ Seem to be able to extend instances outside class definition Reproduce code: --------------- class one{ public $vars; } $inst=new one; $inst->newvar="should make error"; print $inst->newvar; Expected result: ---------------- An error where the class is modified externally to its definition. Actual result: -------------- allows instance to be extended willynilly. Not sure if this is language feature by design - doesnt feel right to my view of OO.