[PHP-DEV] What should I do to create an RFC?

2023-09-29 Thread Saki Takamachi
Hi. I want to create an RFC. This is my first time. The next two pages each have sections on how to create RFCs. However, they differ slightly in content. Which way should I use? https://wiki.php.net/rfc/howto https://wiki.php.net/rfc/voting I already have a wiki account. Is requesting karma

Re: [PHP-DEV] Add bcround, bcfloor, bcceil to BCMath.

2023-09-29 Thread Saki Takamachi
Hi, George. > I think regardless of the issues around round(), ceil(), floor(), etc. > having the equivalent functions for BCMath makes a lot of sense to me. I'm relieved to receive positive feedback. I'll start writing the RFC. There is no doubt that the idea came from the `round()` problem,

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
Hi Dennis On 9/29/23 23:38, Dennis Snell wrote: >> Just chiming in here to say that while we don't offer a createFragment() in >> this proposal, it's possible to parse fragments by passing the >> LIBXML_HTML_NOIMPLIED option. Alternatively, in the future I plan to offer >> innerHTML which you

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Dennis Snell via internals
> Just chiming in here to say that while we don't offer a createFragment() in > this proposal, it's possible to parse fragments by passing the > LIBXML_HTML_NOIMPLIED option. Alternatively, in the future I plan to offer > innerHTML which you could use then in conjunction with >

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
Hi Dennis On 9/29/23 20:20, Dennis Snell wrote: >> >>> >>> For both, `XMLDocument::fromEmpty` and `HTMLDocument::createEmpty` there is >>> an argument available to define the encoding but none of the other >>> `createFrom*` methods have this argument. >>> >>> As far as I understand, in the

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
On 9/29/23 20:22, Larry Garfield wrote: > On Fri, Sep 29, 2023, at 6:12 PM, Niels Dossche wrote: > >>> Unclear to me: Would the XML constants also be aliased into the namespace >>> verbatim, or left globally? >>> >> >> I'll clarify this. >> The intention is to alias them verbatim. > > :thumbs

Re: [PHP-DEV] Add security.txt file to php.net

2023-09-29 Thread Ben Ramsey
On 9/29/23 08:42, Sara Golemon wrote: On Thu, Sep 28, 2023 at 5:20 PM Ben Ramsey wrote: I've added documentation inline in the security.txt file To add some nitpicky bikeshedding, I'd put those instructions elsewhere (maybe php-src:docs/release-process.md ?) and only have a single line in

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Larry Garfield
On Fri, Sep 29, 2023, at 6:12 PM, Niels Dossche wrote: >> Unclear to me: Would the XML constants also be aliased into the namespace >> verbatim, or left globally? >> > > I'll clarify this. > The intention is to alias them verbatim. :thumbs up emoji: >> Did you consider making the new

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Dennis Snell via internals
> >> >> For both, `XMLDocument::fromEmpty` and `HTMLDocument::createEmpty` there is >> an argument available to define the encoding but none of the other >> `createFrom*` methods have this argument. >> >> As far as I understand, in the these other cases the encoding gets detected >> from the

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
Hi Larry On 29/09/2023 18:58, Larry Garfield wrote: > On Fri, Sep 29, 2023, at 7:07 AM, Niels Dossche wrote: >> On 02/09/2023 21:41, Niels Dossche wrote: >>> Hello internals >>> >>> I'm opening the discussion for my RFC "DOM HTML5 parsing and serialization >>> support". >>>

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Larry Garfield
On Fri, Sep 29, 2023, at 5:13 PM, Tim Düsterhus wrote: > Hi > > On 9/29/23 18:58, Larry Garfield wrote: >>> \DOMDocument will also use DOM\Document as a base class to make it >>> interchangeable with the new classes. We're only adding XMLDocument for >>> completeness and API parity. It's a

Re: [PHP-DEV] Add bcround, bcfloor, bcceil to BCMath.

2023-09-29 Thread G. P. B.
On Tue, 26 Sept 2023 at 11:10, Saki Takamachi wrote: > Hi, internals. > > I'm currently working on renovating the `round()` function. > > The current `round()` function rounds a value like 0.285 (0.28499) to > 0.29 using pre-round. > This is a mistake for FP, so discussions are underway to

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Tim Düsterhus
Hi On 9/29/23 18:58, Larry Garfield wrote: \DOMDocument will also use DOM\Document as a base class to make it interchangeable with the new classes. We're only adding XMLDocument for completeness and API parity. It's a drop-in replacement for \DOMDocument, and behaves the exact same. The

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Larry Garfield
On Fri, Sep 29, 2023, at 7:07 AM, Niels Dossche wrote: > On 02/09/2023 21:41, Niels Dossche wrote: >> Hello internals >> >> I'm opening the discussion for my RFC "DOM HTML5 parsing and serialization >> support". >> https://wiki.php.net/rfc/domdocument_html5_parser >> >> Kind regards >> Niels >

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
Hi Tim On 29/09/2023 18:06, Tim Düsterhus wrote: > Hi > > On 9/29/23 17:45, Niels Dossche wrote: >> Right, we follow the HTML spec in this regard. Roughly speaking we determine >> the charset in the following order of priorities. >> If one option fails, it will fall through to the next one. >>

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Tim Düsterhus
Hi On 9/29/23 17:45, Niels Dossche wrote: Right, we follow the HTML spec in this regard. Roughly speaking we determine the charset in the following order of priorities. If one option fails, it will fall through to the next one. 1. The Content-Type HTTP header from which you loaded the

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
Hi Marc On 29/09/2023 09:39, Marc Bennewitz wrote: > Hi Niels, > > On 29.09.23 09:07, Niels Dossche wrote: >> Hi internals >> >> Discussion seems to have died down. >> Today, it's been 14 days since the last major change was done to the RFC >> (i.e. the class hierarchy update). >> And it's also

Re: [PHP-DEV] [RFC] [Discussion] Rounding Integers as int

2023-09-29 Thread Tim Düsterhus
Hi On 9/26/23 12:39, Marc Bennewitz wrote: I'd like to put a new RFC under discussion: https://wiki.php.net/rfc/integer-rounding I find the proposal reasonable, but I don't like the deprecation proposal, because it does not allow me to opt into the *new* behavior before PHP 9.0 arrives.

Re: [PHP-DEV] Add security.txt file to php.net

2023-09-29 Thread Sara Golemon
On Thu, Sep 28, 2023 at 5:20 PM Ben Ramsey wrote: > I've added documentation inline in the security.txt file > To add some nitpicky bikeshedding, I'd put those instructions elsewhere (maybe php-src:docs/release-process.md ?) and only have a single line in the security.txt file referring out to

Re: [PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Marc Bennewitz
Hi Niels, On 29.09.23 09:07, Niels Dossche wrote: Hi internals Discussion seems to have died down. Today, it's been 14 days since the last major change was done to the RFC (i.e. the class hierarchy update). And it's also been close to 4 weeks since I first announced the RFC it on the mailing

Re: [PHP-DEV] [RFC] [Discussion] Rounding Integers as int

2023-09-29 Thread Saki Takamachi
Hi, Marc. > All of these functions already take an `int|float` and therefore the setting > of `strict_types` is irrelevant here on passing float vs. int. Oops, excuse me, I completely misunderstood the signature. Saki -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe,

Re: [PHP-DEV] [RFC] [Discussion] Rounding Integers as int

2023-09-29 Thread Marc Bennewitz
Hi Saki, On 27.09.23 02:18, Saki Takamachi wrote: Hi, Marc. There is one additional case to consider. It's backwards compatible. If `strict_types` is not `1`, the code currently out there may be passing `int` to these functions. Therefore, it is better to be aware that such code can have

[PHP-DEV] Re: [RFC] [Discussion] DOM HTML5 parsing and serialization support

2023-09-29 Thread Niels Dossche
On 02/09/2023 21:41, Niels Dossche wrote: > Hello internals > > I'm opening the discussion for my RFC "DOM HTML5 parsing and serialization > support". > https://wiki.php.net/rfc/domdocument_html5_parser > > Kind regards > Niels Hi internals Discussion seems to have died down. Today, it's been