Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:99783 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 20249 invoked from network); 6 Jul 2017 05:23:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Jul 2017 05:23:24 -0000 Authentication-Results: pb1.pair.com smtp.mail=tysonandre775@hotmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=tysonandre775@hotmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain hotmail.com designates 40.92.14.76 as permitted sender) X-PHP-List-Original-Sender: tysonandre775@hotmail.com X-Host-Fingerprint: 40.92.14.76 mail-oln040092014076.outbound.protection.outlook.com Received: from [40.92.14.76] ([40.92.14.76:11025] helo=NAM05-DM3-obe.outbound.protection.outlook.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A3/35-15131-949CD595 for ; Thu, 06 Jul 2017 01:23:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=ckV0HZ9MHPLG+AUf+nQEWQfENAErYnkRaMCd1ozvd0s=; b=ukE05jjQFsn/bgtBKs+HMvUODlg/YscnSN1eMo4W2NdiT1qbhfrBMrdAwScGL+Xob2vCpZjCB2JMHUwTKOJR5U61cShc0urd0ovMKnYe5oX2SDFhhmfh3e3kvVaMfiN1E+sxa4Xa3oDj5haCtw5toeerUXY/RESsT1hRBj9RJg/c8OEGDB3KGGAb8eoCMQPcFwj8OSRKdU+F6IH+8+u5Rub0QUqO4kaNDLXJaPAI5U2vCZndKxgNxBmOAJ0fV5K2pq1vt4rDW+6Y9XE52MeJet9FbkYmCTaj6t01HTbYS3ccfYMCY8GJ7pk4enOseGiu5EdMKEJN/V7G/OJPUa60uw== Received: from BY2NAM05FT015.eop-nam05.prod.protection.outlook.com (10.152.100.57) by BY2NAM05HT208.eop-nam05.prod.protection.outlook.com (10.152.101.153) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1220.9; Thu, 6 Jul 2017 05:23:18 +0000 Received: from CO2PR07MB569.namprd07.prod.outlook.com (10.152.100.56) by BY2NAM05FT015.mail.protection.outlook.com (10.152.100.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1240.9 via Frontend Transport; Thu, 6 Jul 2017 05:23:18 +0000 Received: from CO2PR07MB569.namprd07.prod.outlook.com ([10.141.230.15]) by CO2PR07MB569.namprd07.prod.outlook.com ([10.141.230.15]) with mapi id 15.01.1240.013; Thu, 6 Jul 2017 05:23:18 +0000 To: Stanislav Malyshev , Nikita Popov CC: "internals@lists.php.net" Thread-Topic: [PHP-DEV] Exposing object handles to userland Thread-Index: AQHS9R30z1+UtSjDnkKzM9jOpTbxI6JE5cQAgADImICAAJRMzw== Date: Thu, 6 Jul 2017 05:23:18 +0000 Message-ID: References: , In-Reply-To: Accept-Language: en-CA, en-US Content-Language: en-CA X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: lists.php.net; dkim=none (message not signed) header.d=none;lists.php.net; dmarc=none action=none header.from=hotmail.com; x-incomingtopheadermarker: OriginalChecksum:967245BCEA2CF656188E46C4448D3EA902685006719A06927503D2E82A7E9065;UpperCasedChecksum:6261C522B06DCB8EF578CB7A78757EFBC52B885751E7FBEA79CFB9B778A6129B;SizeAsReceived:7458;Count:46 x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [L6/YJJCNb/smg8YNTJDmZUx8UlqBAhhf] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BY2NAM05HT208;7:Z2m9qkHZ7bW4ZFxJI60suHpkdRhfEIuw5Ihbo4eV4T0jMkhfZm7zvU9EEiSnkgy75lzEhvf+fPOBYsERyzz74CB5KAje4b7lkApTzeL7uRAYbdOhlTYCUzt/6SPnE6MInHFuj0PUPTCsdaWZ7qkqyhGvUZ1FikzYjzf+OJn3ppfzGJOUDLtYwbZ7CvBgaDWvv6HVVm4Q+xlmShPCEzxA0MinagrkMp8pHLbkcrKoJrCGJBKj7IjWphmN8jtJEaMihfepU0PkL/QQAdKlu1vavqGXp+nXlJioYzvpcD/Wgjt/addsUl5tkv2nFeS5ccW5RxyKL9kH+Zpo0ONxplqOpdXU2a50y8ZFMrcX4JT+xFScLGelo4ci17LE+Q67ppffmlH20G9EujNQseKkzpfbH4DkAPpWHVwCRRm9D0pMqPRxWXw+jM7IdRHqo6cqjSMkYI6KwgmidC0K60wp9ik2FQoTzRN6yey6YtNwETJ0BXnnNW+CxorPJT5FNqOxaaRxfTMd5khx6jP5SiqDLp68KjIEaayBUK4MUYkJhOKk4KUi+/bofh38hy1+6AgbcyFKkIuywE849fvbb0rFLkyIo7aC+tigcGqBjp4vBF67l6SStJvAyjKa5iEXPlqayBaZH8crm6O/L1gP8S3AFxiCwm9XcJt8CqU5r9yrlBNPFD38G4wDhCB4sYu0Mkpp7view8cYq2a5ygdjr3+nDsXfLpIBn/2AzAR0zK1CnTFtur6WsBWIyQ7i0OelKaSQBGFP1kM+vSf8fWFGJoBlyz74tA== x-incomingheadercount: 46 x-eopattributedmessage: 0 x-forefront-antispam-report: EFV:NLI;SFV:NSPM;SFS:(7070007)(98901004);DIR:OUT;SFP:1901;SCL:1;SRVR:BY2NAM05HT208;H:CO2PR07MB569.namprd07.prod.outlook.com;FPR:;SPF:None;LANG:; x-ms-office365-filtering-correlation-id: 595d59ca-f700-4782-6a1d-08d4c42f1c4d x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(300000503095)(300135400095)(201702061074)(5061506573)(5061507331)(1603103135)(2017031320274)(2017031324274)(2017031323274)(2017031322274)(1603101448)(1601125374)(1701031045)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:BY2NAM05HT208; x-ms-traffictypediagnostic: BY2NAM05HT208: x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(444000031);SRVR:BY2NAM05HT208;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:BY2NAM05HT208; x-forefront-prvs: 03607C04F0 spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Jul 2017 05:23:18.1343 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY2NAM05HT208 Subject: Re: [PHP-DEV] Exposing object handles to userland From: tysonandre775@hotmail.com (tyson andre) Updated https://github.com/TysonAndre/php-src/pull/1 , which is now much sh= orter. In response to Nikita Popov's comments: > I'm +1 on the addition and would be fine with including it without RFC, i= f > there are no objections on internals. How long should I wait to see if there are objections before creating a pul= l request? > > - Can two objects can have the same object id > > but different object handlers? > No: In PHP 7 this is not possible, which is also why spl_object_hash() no > longer includes the handlers. True. Checking again, the implementation of spl_object_hash doesn't include the handlers, so I don't need to worry. > You can drop the masking. It was never effective at what it's supposed to > do (hide memory addresses), but as this is the object ID only, it is > completely unnecessary here. > [...] > Only in the sense that it could theoretically wrap around to negative > numbers. Of course those would still serve as IDs just as well. That makes sense. I'm omitting the XOR (and returning the unobfuscated object handle/id) in the proposed change, then.