Re: [PHP-DEV] FPM: Three-Phase running idea for faster frameworks

2021-04-09 Thread Markus Fischer
On 09.04.21 20:22, André Hänsel wrote: Have you tried Roadrunner? I think your design is quite similar (identical?) to what Roadrunner does, only that your worker pool is managed by FPM instead of Roadrunner and that the worker exits after serving one request - which you *can* do with

Re: [PHP-DEV] Changes to Git commit workflow

2021-04-01 Thread Markus Fischer
Hi Bishop, On 01.04.21 06:54, Bishop Bettini wrote: I've documented why we need signing, and how to set it up: https://wiki.php.net/vcs/commit-signing Feedback welcomed! I'm not even the target audience in terms of php-src access, but rarely have I seen such a good tutorial approach on

Re: [PHP-DEV] [RFC] Enumerations, Round 2

2021-01-04 Thread Markus Fischer
On 04.01.21 16:12, Markus Fischer wrote: I can't say whether just `: string` is too much, but in general I like it. Apologies, I meant to write "too magic" :} - Markus -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: https://www.php.net/unsub.php

Re: [PHP-DEV] [RFC] Enumerations, Round 2

2021-01-04 Thread Markus Fischer
Hi, On 04.01.21 15:05, Rowan Tommins wrote: On 04/01/2021 11:15, Markus Fischer wrote: On 03.01.21 12:01, Mike Schinkel wrote: So in my perfect world this: enum BookingStatus {   case PENDING;   case CONFIRMED;   case CANCELLED; } Would be equivalent to: enum BookingStatus

Re: [PHP-DEV] [RFC] Enumerations, Round 2

2021-01-04 Thread Markus Fischer
Hi, On 03.01.21 12:01, Mike Schinkel wrote: So in my perfect world this: enum BookingStatus { case PENDING; case CONFIRMED; case CANCELLED; } Would be equivalent to: enum BookingStatus { case PENDING = "PENDING"; case CONFIRMED = "CONFIRMED"; case

Re: [PHP-DEV] [RFC] Enumerations, Round 2

2020-12-30 Thread Markus Fischer
On 30.12.20 12:00, Rowan Tommins wrote: On 30 December 2020 08:43:33 GMT+00:00, Markus Fischer wrote: What is the scalar value for a ScalarEnum if none is explicitly defined? The question has no answer, because the declaration of the enum itself would be invalid: If an enumeration

Re: [PHP-DEV] [RFC] Enumerations, Round 2

2020-12-30 Thread Markus Fischer
Hi, On 28.12.20 21:21, Larry Garfield wrote: The full RFC is here, and I recommend reading it again in full given how much was updated. https://wiki.php.net/rfc/enumerations I tried to answer the following question but failed to do so: What is the scalar value for a ScalarEnum if none is

Re: [PHP-DEV] [RFC] Enumerations

2020-12-05 Thread Markus Fischer
Hi, On 05.12.20 10:22, Pierre R. wrote: I think that ::cases() should always return an array/iterable without keys, and let userland write their own code to create hashmaps with those when they need it. I think that having one case (non primitive cases) that doesn't yield string keys and the

Re: [PHP-DEV] Attributes and constructor property promotion

2020-10-07 Thread Markus Fischer
Hi! On 06.10.20 17:15, Sara Golemon wrote: My opinion on constructor property promotion (CPP) is that it's something for small value object classes and should probably be regarded as code-smell on larger classes. At the same time, annotations belong with more complex objects and not so much

Re: [PHP-DEV] RFC: Support for multi-line arrow functions

2020-10-05 Thread Markus Fischer
On 05.10.20 12:24, Andreas Leathley wrote: On 05.10.20 12:08, Lynn wrote: How should php deal with the scenario where you want to `use` everything and have one variable by reference? ``` function () use (*, &$butNotThisOne) {}; ``` The easiest would be to only allow "use (*)" with no

Re: [PHP-DEV] Draft RFC: foreach iteration of keys without values

2020-09-03 Thread Markus Fischer
Hi, On 03.09.20 09:58, Côme Chilliet wrote: foreach ($iterable as $key => $_) { ... } I currently use foreach (array_keys($array) as $key) { ... } to avoid complains from code analysers on unused var, is it slower? one argument brought forward initially (sorry, can't find the email

Re: [PHP-DEV] Request for couple memory optimized array improvements

2020-08-31 Thread Markus Fischer
On 31.08.20 20:13, Riikka Kalliomäki wrote: Another similar problem with creating array copies is the detection of "indexed" arrays (as opposed to associative arrays). I'm looking forward to an answer from someone proficient in this area because _I think_ the engine _internally_ keeps track

Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change

2020-08-10 Thread Markus Fischer
On 10.08.20 13:32, Jordi Boggiano wrote: https://gist.github.com/Seldaek/b7a3bd28920c6cc181e67a829b13a81c This is really really useful! However I suggest to look at the raw text rather, because the highlighting is unaware of the syntax and may bias "how it feels to look at it" (*):

Re: [PHP-DEV] [RFC] Nullsafe operator

2020-07-14 Thread Markus Fischer
Hi, On 14.07.20 10:51, Ilija Tovilo wrote: Would this still work together with short-circuiting and the null coalesce operator? $country = $session?->user?->getAddress()?->country ?? 'defaultCountry'; Yes, your example will still work, this is solely about references :) Thanks for

Re: [PHP-DEV] [RFC] Nullsafe operator

2020-07-14 Thread Markus Fischer
Hi Ilija, I'd like to introduce another RFC I've been working on: https://wiki.php.net/rfc/nullsafe_operator It introduces the nullsafe operator ?-> that skips null values when calling functions and fetching properties. In contrast to the last few attempts this RFC includes full short

Re: [PHP-DEV] [RFC] Shorter attribute syntax

2020-06-08 Thread Markus Fischer
Hi Theodore, On 08.06.20 06:36, Theodore Brown wrote: ```php // 170 characters for attributes (162 not counting leading whitespace) << ManyToMany(Phonenumber::class), JoinTable("users_phonenumbers"), JoinColumn("user_id", "id"), InverseJoinColumn("phonenumber_id", "id",

Re: [PHP-DEV] [RFC] Mixed type

2020-04-24 Thread Markus Fischer
On 24.04.20 16:33, Bob Weinand wrote: Actually, Really had to laugh, reading your previous and then this mail :-) I forgot that for proper generics implementations, collections etc. will obviously need to specify "allowing any type". As such the introduction of mixed is pretty much

Re: [PHP-DEV] [RFC] Mixed type

2020-04-20 Thread Markus Fischer
Hi, just picking on one of the examples: On 20.04.20 17:45, Benjamin Eberlei wrote: - json_encode, serialize, and more generally serialization and encoding functions, as return value as well for the inverse operations But how would this work for serializing resources, which is part of

Re: [PHP-DEV] [RFC] Constructor Property Promotion

2020-04-02 Thread Markus Fischer
Him On 02.04.20 12:07, Nikita Popov wrote: Reflection will see the state after desugaring. That is, it just sees normal properties and normal constructor args. I've made this more explicit in the RFC now: https://wiki.php.net/rfc/constructor_promotion#reflection Thanks! Another one, also

Re: [PHP-DEV] [RFC] Constructor Property Promotion

2020-04-01 Thread Markus Fischer
Hi, On 2020-03-26 14:30, Nikita Popov wrote: I would like to submit the following RFC for your consideration: https://wiki.php.net/rfc/constructor_promotion This is based on one off the suggestions made in https://externals.io/message/109220, and some existing discussion on the topic can be

Re: [PHP-DEV] PHP 7.4.1 Released!

2019-12-18 Thread Markus Fischer
On 18.12.19 12:45, Derick Rethans wrote: Changelog: I think the date here is wrong, it says "19 Dec 2019" but it's the 18th today 路‍♀️ - Markus -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit:

Re: [PHP-DEV] Re: Adding explicit intent for SWITCH/CASE fall through?

2019-10-18 Thread Markus Fischer
On 18.10.19 00:07, Mike Schinkel wrote: case 'educationtype': $update = false; fallthrough; I was about to suggest `continue`, alas we know that would clash :-) Suggestion: `next;` instead? - Markus -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe,

Re: [PHP-DEV][RFC] Alternative "use" syntax for Closures

2019-06-16 Thread Markus Fischer
Hi, On 15.06.19 23:53, Wes wrote: https://wiki.php.net/rfc/alternative-closure-use-syntax Thanks for the RFC and effort, I know it seems overkill and wrong to have two different syntaxes for the same thing, but I really believe that's all we need to fix one of the most hated PHP syntax

Re: [PHP-DEV] Re: [RFC] Numeric Literal Separator

2019-05-29 Thread Markus Fischer
Hi, On 29.05.19 09:49, Côme Chilliet wrote: What bugs me with this RFC is that it seems to be mainly intended for grouping digits by 3, which from what I understand is cultural. At least some asian languages have a concept of https://en.wikipedia.org/wiki/Myriad and group them by 4, at least

Re: [PHP-DEV] Re: [RFC] Arrow functions / short closures

2019-04-10 Thread Markus Fischer
Hi, Gabriel, On 10.04.19 10:33, Gabriel O wrote: Those parentheses are important when having multiple argument Please don't top post, thanks! Thanks for pointing it out, I'm aware. Still `===>` would better stand out to _me_ personally. thanks, - Markus -- PHP Internals - PHP Runtime

Re: [PHP-DEV] Re: [RFC] Arrow functions / short closures

2019-04-10 Thread Markus Fischer
On 10.04.19 00:10, Robert Hickman wrote: - $waithandles = $this->urls->map(fn($url) => $this->fetcher->fetch($url)); - $waithandles = $this->urls->map(\($url) => $this->fetcher->fetch($url)); - $waithandles = $this->urls->map($url ==> $this->fetcher->fetch($url)); I would say that when lambda

Re: [PHP-DEV] Offset-only results from preg_match

2019-03-20 Thread Markus Fischer
On 19.03.19 15:58, Nikita Popov wrote: I'm wondering if we shouldn't consider a new object oriented API for PCRE which can return a match object where subpattern positions and contents can be queried via method calls, so you only pay for the parts that you do access. Or also a literal syntax

Re: [PHP-DEV] Offset-only results from preg_match

2019-03-16 Thread Markus Fischer
On 14.03.19 20:33, C. Scott Ananian wrote: ps. more ambitious would be to introduce a new "substring" type, which would share the allocation of a parent string with its own offset and length fields. That would probably be as invasive as the ZVAL_INTERNED_STR type, though -- a much much bigger

Re: [PHP-DEV] [RFC] Permit trailing whitespace in numeric strings

2019-03-05 Thread Markus Fischer
Hello, On 06.03.19 01:16, Andrea Faulds wrote: https://wiki.php.net/rfc/trailing_whitespace_numerics I expect this should be an uncontroversial proposal, but maybe I'm jinxing it there. I hope you all like it. :) Thanks to Nikita for reminding me it existed and thus motivating me to pick

Re: [PHP-DEV] phpenmod/phpdismod

2019-02-03 Thread Markus Fischer
Hi, On 04.02.19 07:24, Remi Collet wrote: Le 02/02/2019 à 20:24, Legale Legage a écrit : These scripts are included to the standard deb/rpm packages No, this is a deb only stuff RPM installed = extension enabled. Remi P.S. I have never understand the need of such tools... did it made

Re: [PHP-DEV] Deprecation ideas for PHP 8

2019-01-23 Thread Markus Fischer
Hi, On 22.01.19 21:34, Girgias wrote: - phpversion (use PHP_VERSION constant) The function takes an optional argument `string $extension`, what is the replacement for that? - intval (for arbitrary base change there exists the math function base_convert) I've seen and myself

Re: [PHP-DEV] Making stdClass iterable

2019-01-12 Thread Markus Fischer
On 12.01.19 21:13, Dan Ackroyd wrote: Hi Duncan, [...] great points I was about to reply to Craig when Dans' email hit the list. I couldn't agree with Dan more. The expanded use of stdClass feels wrong to me, as in: wrong solution to a problem best solved differently. Dan gave ample

Re: [PHP-DEV] [RFC] FFI - Foreign Function Interface

2018-12-11 Thread Markus Fischer
On 11.12.18 16:42, Marco Pivetta wrote: > People who don't know what FFI is, don't need it. I think this is a very dangerous way of designing, writing and documenting software. I appreciate your efforts in pushing this forward, but please reconsider when approaching the naming problematic,

Re: [PHP-DEV] Add FILTER_VALIDATE_INCLUDE validation filter for variable includes

2018-09-22 Thread Markus Fischer
On 21.09.18 14:07, Andrey Andreev wrote: On Fri, Sep 21, 2018 at 3:03 PM, Rowan Collins wrote: Hi Arnold, Please remember to click "Reply All" / "Reply List" rather than just "Reply", to make sure the list is included in your replies. Right now, most of us are only seeing half the

Re: [PHP-DEV] Re: PHP 7.3 Release Manager Selection

2018-05-01 Thread Markus Fischer
On 01.05.18 20:19, Sara Golemon wrote: With 7.3.0-alpha1's date on June 7th I'd like to have RMs confirmed by mid-May. To that end, I'm placing a deadline on nomination/acceptance of April 30th and will be opening the vote (assuming we have more than 2) on May 1st. Whelp! It's May day, and

Re: [PHP-DEV][RFC][DISCUSSION] Deprecate the backtick operator

2018-02-13 Thread Markus Fischer
On 2018-02-11 20:41, Wes wrote: Hello PHPeople, I present to you... the shortest RFC ever. https://wiki.php.net/rfc/deprecate-backtick-operator Let me know what you think! I don't have much of an opinion yet on the issue (observing the arguments in the discussion so far), but one thing

Re: [PHP-DEV] Shorthand proposal for associative arrays

2018-01-27 Thread Markus Fischer
Hi, On 28.01.18 03:51, Christian Schneider wrote: 2) More importantly: It hides the variable being used: 'src' instead of $src which makes it harder to search for the variable or statically analyse the code. I'm not sure about that argument. compact() been around basically since forecer.

Re: [PHP-DEV] [RFC] [DISCUSSION] Scalar Pseudo-type

2017-12-29 Thread Markus Fischer
Hi all, On 26.12.17 16:56, Sebastian Bergmann wrote: Am 26.12.2017 um 16:46 schrieb li...@rhsoft.net: would you mind to explain this? "Foo|Bar", "array|string", etc. (still) make no sense to me. "scalar" makes sense to me although it is but an alias for "bool|float|int|string". I followed

Re: [PHP-DEV] [RFC]Discuss] Syntax for Arrow Functions

2017-06-20 Thread Markus Fischer
Hello Rasmus, On 19.06.17 22:22, Rasmus Schultz wrote: If I have to factor back and forth between new and old syntax every time a closure changes from one to multiple or back to one statement, then, frankly, what's the point? I think I would just keep using the old syntax, then - for

Re: [PHP-DEV] Snapping php

2017-05-10 Thread Markus Fischer
On 10.05.17 16:05, Alan Pope wrote: What we're really after though is feedback. We've got documentation [3], tutorials [4] and a fourm [5] where the developers hang out. We're keen to know where the rough edges are, and what we can do to improve the experience for developers and users alike.

Re: [PHP-DEV] [RFC] Enable strict_types checking for curl_setopt()

2017-04-30 Thread Markus Fischer
Hi, On 29.04.17 17:53, Sara Golemon wrote: 1. If the parameter isn't reflectable, then it shouldn't be subject to enforcement. This argument holds no water because internal functions can only reflect array or object type hints, yet we enforce other types routinely. I selected unfortunate

Re: [PHP-DEV] [RFC] Enable strict_types checking for curl_setopt()

2017-04-28 Thread Markus Fischer
Hi, On 22.04.17 13:40, Colin O'Dell wrote: Hello internals, I'd like to propose an enhancement to curl_setopt() which is used to configure a given curl session. The second argument of this function defines which option to set and the third

Re: [PHP-DEV][RFC][VOTE] Throwable error code's type generalization

2017-01-19 Thread Markus Fischer
Hi, On 06.01.17 18:02, Wes wrote: > Greeting fellow elePHPants and happy new year. > > I've just started the vote for the RFC in subject. You can find it here: > > https://wiki.php.net/rfc/throwable-code-generalization The RFC states: "In practice this is mostly a documentation change ... "

[PHP-DEV] Outdated links on https://wiki.php.net/systems

2017-01-18 Thread Markus Fischer
On 18.01.17 10:44, Maciej Sobaczewski wrote: > I will ask differently: will wiki.php.net/systems be updated afterwards? > I saw a few outdated links there, maybe someone can correct/remove them? Within "Machine Status" - "public network status" http://monitoring.php.net/status/ => 404 -

Re: [PHP-DEV] Change in type-hint representation

2017-01-11 Thread Markus Fischer
On 11.01.17 13:07, Dmitry Stogov wrote: > https://gist.github.com/dstogov/1b25079856afccf0d69f77d499cb0ab1 - there's a typo "/* this is a calss name */" a few times - a few times I see this condition: "if (info->type > 0x3ff) {" Shouldn't we use *some* descriptive constant for this seamingly

Re: [PHP-DEV][RFC][DISCUSSION] - Immutable classes and properties

2016-12-13 Thread Markus Fischer
Hello, On 13.12.16 10:17, Silvio Marijić wrote: > After much thinking regarding array in immutable objects I'm thinking of > revoking this RFC. If someone has some suggestion on that matter now is the > time, but otherwise my work is done on this one. It would be nice if you could summarize the

Re: [PHP-DEV] [RFC][VOTE] User defined session serializer

2016-12-04 Thread Markus Fischer
Hi, On 05.12.16 02:44, Yasuo Ohgaki wrote: > This RFC exposes session serializer interface to user space. It works > like user defined session save handler. > > Users are able to encrypt/validate session data transparently. e.g. > You can save encrypted session data to database, decrypt

Re: [PHP-DEV] [RFC DISCUSSION] User defined session serializer

2016-11-18 Thread Markus Fischer
Hello, On 17.11.2016 11:55, Yasuo Ohgaki wrote: > > Session module implements serialize handler as module. > This RFC is to expose it to user space. > > RFC > https://wiki.php.net/rfc/user_defined_session_serializer > > PR > https://github.com/php/php-src/pull/2205 > > Comments are

Re: [PHP-DEV] [RFC][DISCUSSION] Object type hint

2016-10-24 Thread Markus Fischer
Hi, On 23.10.16 09:39, Michał Brzuchalski wrote: > I would like to initiate discussion for Object typehint RFC > https://wiki.php.net/rfc/object-typehint > > This feature is developed to provide missing functionality which is needed > and quite easy to introduce. > There are many people which

Re: [PHP-DEV] [RFC] Counting of non-countable objects

2016-10-04 Thread Markus Fischer
Hi, On 04.10.16 11:32, Craig Duncan wrote: > I'd like to propose the introduction of warning when counting objects that > can't be counted. > > The default behaviour is to return 1 for these objects, which can be > misleading and hide bugs when attempting to count iterable objects (eg >

[PHP-DEV] About session.use_strict_mode=0 by default (was: Re: [PHP-DEV] [RFC][VOTE] Session ID without hashing)

2016-07-02 Thread Markus Fischer
Everytime I see a thread mentioning session.use_strict_mode I'm wondering why we haven't got around to enable it by default (by means of php.ini-development/php.ini-production ). Maybe someone can step forward and propose this change for the next version (not 7.1 ...)? It could be documented as

Re: [PHP-DEV] New escaped output operator

2016-07-01 Thread Markus Fischer
On 01.07.16 05:34, Михаил Востриков wrote: > Because it is almost impossible to add template engine in a big project > with PHP templates. But new version of language usually can easily be used. I interpret "But new version of language usually can easily be used" as in a new PHP version being

Re: [PHP-DEV] [RFC] [Vote] Callable types (now: Callable prototypes)

2016-05-23 Thread Markus Fischer
Hello Nikita, On 23.05.16 21:27, Nikita Nefedov wrote: > When you pass an `int` to a `string` type parameter in weak mode > it's being coerced to the needed type (not just directly passed). > > This is quite complex, because you'd need to copy zend_function > and all its members (without

Re: [PHP-DEV] [RFC] Square bracket syntax for array destructuring assignment

2016-04-07 Thread Markus Fischer
Hey, On 07.04.2016 14:21, Andrea Faulds wrote: > Bob and I have made an RFC which proposes an alternative syntax for list(): > > https://wiki.php.net/rfc/short_list_syntax > > Please tell us your thoughts. Reading the last sample in the RFC: > Both due to implementation issues, and for

Re: [PHP-DEV] [RFC][DISCUSSION] Session ID without hashing

2016-04-07 Thread Markus Fischer
On 06.04.2016 07:47, Yasuo Ohgaki wrote: > Session module does not require hashing to generate session ID. This > RFC removes hashing from session module and enable use_strict_mode as > an insurance for broken RNG. > > https://wiki.php.net/rfc/session-id-without-hashing I cannot talk about the

Re: [PHP-DEV] [RFC] Traits with interfaces

2016-02-17 Thread Markus Fischer
Hello, On 17.02.16 15:25, Kevin Gessner wrote: > I've noticed s pattern in Etsy's code and elsewhere, where a trait provides > a common implementation of an interface. Classes that use the trait are > required to also explicitly declare the interface to benefit. I propose > that traits be

Re: [PHP-DEV] Proposal for a new array function

2016-02-08 Thread Markus Fischer
Hi, On 08.02.16 18:06, Cesar Rodas wrote: >>> return array_keys($arr) !== range(0, count($arr) - 1); > > `array_keys($array) === range(0, count($array)-1)` That approach would fall flat when the numeric keys are not consecutive: $array = [1=>"a", 3=>"b"]; Disclaimer: AFAIK complete goal of

Re: [PHP-DEV] Throwable and Error exceptions break existing PHP 5.x code

2016-01-11 Thread Markus Fischer
Dear Giovanni, I brought this up last July, see https://bugs.php.net/bug.php?id=70050 ; because in a few code bases I tested back then, this was the first issue I hit. Unfortunately, it was only deemed a "Documentation Problem" back then. AFAIK this is the most up to date information. Sorry I

Re: [PHP-DEV] POST request to fastcgi FPM with chunked encoding does not properly return result

2016-01-03 Thread Markus Fischer
yet. On 23.12.15 23:15, Markus Fischer wrote: > Hello, > > I wrote up a detailed question at SO but I had a hunch it could be a > real bug ( > http://stackoverflow.com/questions/34440220/post-request-to-php7-with-chunked-encoding-does-not-properly-return-result > ). > > B

[PHP-DEV] POST request to fastcgi FPM with chunked encoding does not properly return result

2015-12-23 Thread Markus Fischer
Hello, I wrote up a detailed question at SO but I had a hunch it could be a real bug ( http://stackoverflow.com/questions/34440220/post-request-to-php7-with-chunked-encoding-does-not-properly-return-result ). Basically, a POST request to php-fpm with "Transfer-Encoding: chunked" and post data

Re: [PHP-DEV] [RFC] [PHP 7.1] libsodium

2015-05-22 Thread Markus Fischer
On 21.05.2015 03:15, Scott Arciszewski wrote: I've just opened an RFC for precisely this purpose: https://wiki.php.net/rfc/libsodium From https://github.com/jedisct1/libsodium-php : // Binary to hexadecimal $hex = Sodium::sodium_bin2hex($bin); // Hexadecimal to binary $bin =

Re: [PHP-DEV] [VOTE] Reclassify E_STRICT notices

2015-03-16 Thread Markus Fischer
Hi Matteo, On 16.03.15 12:43, Matteo Beccati wrote: On 15/03/2015 19:30, Matteo Beccati wrote: In PHP4 times it was in fact quite common to change inherited method signatures to bend them to one's will and/or remove parameters and hardcode them in the parent constructor call. We now know it

Re: [PHP-DEV] [VOTE] Reclassify E_STRICT notices

2015-03-15 Thread Markus Fischer
On 15.03.15 16:46, Nikita Popov wrote: To ensure we have no shortage of new RFC votes... https://wiki.php.net/rfc/reclassify_e_strict#vote Voting is open for ten days :) From the RFC: Signature mismatch during inheritance ... Possible alternative: Convert to E_DEPRECATED, if we intend

Re: [PHP-DEV] [RFC] Basic Scalar Types

2015-03-12 Thread Markus Fischer
On 11.03.15 22:28, Bob Weinand wrote: after all, some people are not happy with the current proposals about scalar types. So, they both still possibly may fail. Thus, I'd like to come up with a fallback proposal in case both proposals fail: https://wiki.php.net/rfc/basic_scalar_types

Re: [PHP-DEV] Consistent function names

2015-03-02 Thread Markus Fischer
On 03.03.15 00:10, Yasuo Ohgaki wrote: I would love to have new clean APIs. Please think my proposal as legacy API cleanups. Many of candidates will remain without CORDING_STANDARSDS confirmed names almost forever. This is what I would like to improve. If you don't care about legacy stuff

Re: [PHP-DEV] Consistent function names

2015-03-01 Thread Markus Fischer
On 01.03.15 13:53, Rowan Collins wrote: On 1 March 2015 11:29:49 GMT, Yasuo Ohgaki yohg...@ohgaki.net wrote: How about rename all of these functions according to CODING_STANDARD for PHP7 and have aliases for old names? If this list had an FAQ (which I think it should), this would be on

Re: [PHP-DEV] Consistent function names

2015-03-01 Thread Markus Fischer
Hello! On 01.03.15 21:19, Yasuo Ohgaki wrote: The answer is no, it's just not worth it. Having a function called str_pos which is an alias of strpos, but only on some versions, is more confusing, not less. My sentiment too. Factor in that someone already using the proposed himself, things

Re: [PHP-DEV] Coercive Scalar Type Hints RFC

2015-02-21 Thread Markus Fischer
Hi Zeev, On 21.02.15 18:22, Zeev Suraski wrote: I’ve been working with François and several other people from internals@ and the PHP community to create a single-mode Scalar Type Hints proposal. I think it’s the RFC is a bit premature and could benefit from a bit more time, but given the

Re: [PHP-DEV] [VOTE] Expectations

2015-02-20 Thread Markus Fischer
On 19.02.15 16:23, Dmitry Stogov wrote: - how does zend.assertions and assert.exceptions work with assert_options() , i.e. isn't the exception behavior meant to be an addition to assert_options() too ? zend.assertions control assert() compilation and execution zend.assertions=-1

Re: [PHP-DEV] [RFC] Comparable: the revenge

2015-02-20 Thread Markus Fischer
On 19.02.15 22:40, Adam Harvey wrote: Those of you with long memories will remember that I proposed a Comparable interface way back in the pre-5.4 days, but withdrew it when it became obvious that there was no consensus for it as a feature and that a vote was likely to fail. RFC:

Re: [PHP-DEV] [RFC] Make empty() a Variadic

2015-02-20 Thread Markus Fischer
On 21.02.15 06:11, Thomas Punt wrote: Hello Internals! The following RFC aims to make empty() have a variable arity: https://wiki.php.net/rfc/variadic_empty. This is a simple feature that enables for a short-hand notation of checking multiple expressions for emptiness (which is a pretty

Re: [PHP-DEV] [RFC][Discussion] In Operator

2015-02-20 Thread Markus Fischer
On 20.02.15 18:16, Dan Ackroyd wrote: On 20 February 2015 at 12:54, Niklas Keller m...@kelunik.com wrote: Hi internals, It would really make sense to vote on this RFC after there has been a vote on https://wiki.php.net/rfc/context_sensitive_lexer. That is an understatement:

Re: [PHP-DEV] [RFC] Reserve EVEN MORE types for PHP7

2015-02-20 Thread Markus Fischer
On 20.02.15 18:55, Sara Golemon wrote: Announcing this in its own thread: https://wiki.php.net/rfc/reserve_even_more_types_in_php_7 This RFC acts as an addition to Levi's https://wiki.php.net/rfc/reserve_more_types_in_php_7 by creating a forum for voting on additional types not included in

Re: [PHP-DEV] [RFC] Reserve EVEN MORE types for PHP7

2015-02-20 Thread Markus Fischer
On 20.02.15 18:55, Sara Golemon wrote: Announcing this in its own thread: https://wiki.php.net/rfc/reserve_even_more_types_in_php_7 This RFC acts as an addition to Levi's https://wiki.php.net/rfc/reserve_more_types_in_php_7 by creating a forum for voting on additional types not included in

Re: [PHP-DEV] [VOTE] Expectations

2015-02-19 Thread Markus Fischer
Hi, On 19.02.15 10:09, Joe Watkins wrote: Morning internals, The expectations RFC is now in voting phase: https://wiki.php.net/rfc/expectations#vote - I somehow miss information what the exact differences are to the current implementation, to better judge the impact. - how does

Re: [PHP-DEV][RFC][VOTE] Group Use Declarations

2015-02-14 Thread Markus Fischer
2015-02-13 13:50 GMT-03:00 Nikita Popov nikita@gmail.com: use PhpParser\NodeVisitorAbstract; use PhpParser\Error; use PhpParser\Node; use PhpParser\Node\Name; use PhpParser\Node\Name\FullyQualified; use PhpParser\Node\Stmt\Namespace_; use PhpParser\Node\Stmt\Use_; use

Re: [PHP-DEV] [RFC][DISCUSSION] Script only includes

2015-02-10 Thread Markus Fischer
On 10.02.15 01:52, Yasuo Ohgaki wrote: Some of you are tired with this topic, but please take a look the RFC [RFC] Script only includes - this is 3rd version. https://wiki.php.net/rfc/script_only_include Please let me know what you like or dislike. How exactly does this detection work?

Re: [PHP-DEV] [RFC] Scalar Type Hints v0.2

2015-02-02 Thread Markus Fischer
Hello Andrea, On 02.02.15 00:49, Andrea Faulds wrote: The RFC has been updated to cover return types, since Levi’s Return Types RFC has passed. The patch is a work in progress: it works, but lacks tests for return types. Version 0.3 of the RFC can be found here:

Re: [PHP-DEV] [VOTE] Combined Comparison (Spaceship) Operator

2015-02-02 Thread Markus Fischer
On 02.02.15 14:49, Nikita Popov wrote: I've voted -1 because I think this should be a function and not an operator. compare($a, $b) is more obvious than $a = $b and it's not like writing comparison functions is such a super common use case that it needs the extra brevity of an operator. A

Re: [PHP-DEV][RFC][DISCUSSION] Group Use Declarations

2015-01-31 Thread Markus Fischer
On 31.01.15 01:09, Marcio Almada wrote: After a period of research along with part of the PHP community I'd like to present this RFC which aims to improve PHP namespaces. The RFC: https://wiki.php.net/rfc/group_use_declarations Along with its pull request:

Re: [PHP-DEV] journald support for Linux systems that use systemd

2015-01-08 Thread Markus Fischer
On 08.01.15 02:14, Johannes Schlüter wrote: On Wed, 2015-01-07 at 17:01 -0500, Mark Montague wrote: I'd like to start an RFC (see the draft proposal at the end of this message) for adding journald support to PHP on Linux systems that use systemd. This message is to measure reaction to

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-04 Thread Markus Fischer
On 04.01.15 04:43, Pierre Joye wrote: I agree with your sentiments about data loss, but I am reluctant to deviate much from the behaviour of internal functions to avoid the inconsistency that plagued the previous RFC. Right, but this is what I would expect. Am I the only one? Definitely

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-03 Thread Markus Fischer
On 03.01.2015 05:50, Pierre Joye wrote: I am also not a fan of errors, exception, at least for methods, make much more sense. I know it is relatively easy to handle errors as exception but still, let do it right now. I second this; this could be an excellent opportunity into that direction

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-02 Thread Markus Fischer
Hello Jordi, On 02.01.2015 15:01, Jordi Boggiano wrote: Looking at it from an OSS maintainer perspective, introducing strict hints in code would be a huge BC break as I don't know how people use my code, nor if they validate/coerce their user input early or not. If I suddenly declare

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-02 Thread Markus Fischer
On 02.01.15 05:36, Levi Morrison wrote: I don't necessarily have any more insight to provide than has already been done, but I do want to chime in and say that I personally favor strict types as Nikita Popov has been advocating. Same from me. I support all arguments so far made by Nikita;

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-01 Thread Markus Fischer
Hello Sebastian, On 01.01.15 09:28, Sebastian Bergmann wrote: Am 31.12.2014 um 21:27 schrieb Andrea Faulds: Parameter type hints for PHP’s scalar types Please use the term type declaration for arguments (or type declaration for parameters) instead of type hints. If it's used then it's

Re: [PHP-DEV] [RFC] Scalar Type Hints

2015-01-01 Thread Markus Fischer
Hello Andrea, On 01.01.15 16:19, Andrea Faulds wrote: I think it’d be weird to have different syntaxes for scalars and non-scalars. We already use the syntax the RFC proposes in the PHP manual, and I don’t think anyone’s confused by it. I didn't meant to stay there's something wrong with

Re: [PHP-DEV] [RFC][VOTE] Objects as Keys

2014-12-16 Thread Markus Fischer
On 16.12.14 09:34, Stanislav Malyshev wrote: I'd like to initiate a vote on objects as keys RFC: https://wiki.php.net/rfc/objkey Am I right this only covers the transformation into the array. Once it's in it's essential a array compatible key entity (string/integer) so when you var_dump($array)

Re: [PHP-DEV] [VOTE][RFC] Unicode Codepoint Escape Syntax

2014-12-13 Thread Markus Fischer
On 09.12.14 00:51, Andrea Faulds wrote: Good evening, I’m opening voting on the Unicode Codepoint Escape Syntax RFC. There’s been some discussion in the last two weeks since I introduced the RFC, but there’s nothing left which I feel needs changing. For the character name syntax

Re: [PHP-DEV] [RFC] Unicode Escape Syntax

2014-11-25 Thread Markus Fischer
On 24.11.14 23:09, Andrea Faulds wrote: Good evening, Here’s a new RFC: https://wiki.php.net/rfc/unicode_escape I think the choice of \u{xx} is interesting, i.e. using '{' and '}'. Afaik, one of the current best practices is to use json_decode(), like so: $ cat test.php ?php var_dump(

Re: [PHP-DEV] Reflection-API

2014-10-20 Thread Markus Fischer
Hi Chris, On 20.10.14 12:10, Chris Wright wrote: [...] in depth summary of future idea ReflectionType Thanks a lot for the clarification and regarding the future expansion of the use of ReflectionType I now better understand most points and why they're currently are that way. I don't think I've

[PHP-DEV] Reflection-API (was: Re: [PHP-DEV] RFC: Return Types Update)

2014-10-19 Thread Markus Fischer
On 16.10.14 06:39, Levi Morrison wrote: - The design and accompanying section of reflection[3] has been rewritten entirely. [3]: https://wiki.php.net/rfc/returntypehinting#reflection I've some comments about the Reflection API addition/changes: 1. Note that getReturnType will always

Re: [PHP-DEV] [RFC] Exceptions in the engine

2014-10-07 Thread Markus Fischer
On 07.10.2014 14:15, Ferenc Kovacs wrote: yes, this was also suggested before, but that will be also a BC break for those people already using the name of the new parent class ( https://github.com/search?l=phpq=EngineExceptiontype=Codeutf8=%E2%9C%93 for example). which can be still an ok

Re: [PHP-DEV] [VOTE] Fix list() behavior inconsistency

2014-09-25 Thread Markus Fischer
On 25.09.14 09:42, Dmitry Stogov wrote: The vote is opened at https://wiki.php.net/rfc/fix_list_behavior_inconsistency Voted +1 for disabling. I think string handling needs more thorough designing and planning for edge case and such; i.e. the string handling alternative seems to rushed to me

Re: [PHP-DEV] ext/standard/tests/http/bug60570.phpt failure

2014-08-20 Thread Markus Fischer
Hello Dmitry, On 20.08.2014 12:08, Dmitry Stogov wrote: To have a robust way to detect resource leaks I propose a new function - get_resources() that returns an array of all registered resources or an array of registered resources of particular type. See patch:

Re: [PHP-DEV] '?=' with PHP5.3.10

2012-03-06 Thread Markus Fischer
On 06.03.2012 00:08, Lester Caine wrote: The ISP hosting these sites has not got back to me yet, but it would seem that when they updated from 5.3.9 to 5.3.10 they also switched off short_open_tag when previously it had been on. I've learned it also the hard way the ISPs or Hosters did change

Re: [PHP-DEV] Scary note for gettype() in docs

2010-03-01 Thread Markus Fischer
On 01.03.2010 21:35, Stan Vassilev wrote: The gettype() documentation warns people that the returned string is subject to change. Why is there a function that's subject to change in the API? Probably because of the unicode stuff, might suddenly return unicode (still true? don't know) or binary

Re: [PHP-DEV] Re: RFC: Replacing errors with Exceptions

2009-07-30 Thread Markus Fischer
Hannes Magnusson wrote: On Thu, Jul 30, 2009 at 20:28, Joey Smithj...@joeysmith.com wrote: However, now that it's come up, I'm wondering what the costs/risks are of setting libxml_use_internal_errors() on by default? I don't think thats a good idea. People are used to getting a warning when

Re: [PHP-DEV] RFC: Replacing errors with Exceptions

2009-07-24 Thread Markus Fischer
Hello, u...@domain.invalid wrote: I published a (work in progress) RFC today about replacing certain errors with exceptions. I know that there already was something similiar on the php6dev blog, but this is not completly the same, so awating your comments:

[PHP-DEV] ini value of On = 1 and Off = ? (Re: [PHP-DEV] RFC for new INI's)

2009-02-10 Thread Markus Fischer
Sorry to hijack, but ... Christopher Jones wrote: oci8.events and oci8.old_oci_close_semantics are boolean, so we can take this opportunity to change the 1 and 0 to On and Off. ... I've never understood why writing On/Off is a good idea, when it is not intuitive that the value returned from

  1   2   3   >