« first day (3974 days earlier)      last day (973 days later) » 

12:00 AM
Hey, does any here use Chrome on Linux? There's an odd font glitch when two ff is in a word for me on the RFC site, e.g. wiki.php.net/rfc/increment_decrement_fixes
I've seen it on previous installs as well for a long time, just wondering if anyone else sees it.
 
that's some shitty kerning
 
Never seen it on any other site
and the bold and italic variations are not affected.
Happens on both KDE and MATE
 
I thought MATE was a caffeinated German soda?
 
Mate or maté also known as chimarrão or cimarrón, is a traditional South American caffeine-rich infused drink. It is made by soaking dried leaves of the holly species Ilex paraguariensis in hot water and is served with a metal straw in a container typically made from a calabash gourd. Yerba Mate was consumed by the Guaraní and Tupí peoples. It has been consumed in America since pre-Columbian times. Its consumption was exclusive to the natives of two regions of the territory that today is Paraguay, more specifically the departments of Amambay and Alto Paraná. Some ethnic groups that consumed it...
 
12:08 AM
Yeah, a word can be more than one thing
 
No shit? Which languages does that o_O
 
Well I'm a bit confused about the relevance I guess
 
i wouldnt worry about that
 
 
2 hours later…
2:21 AM
shmop_open won't attach and causes php to crash ・ Reproducible crash ・ #81407
 
 
1 hour later…
3:53 AM
Sheesh! I graduated high school the year she was born
 
4:33 AM
Ouch
 
4:44 AM
@ramsey That is really great! I'll try to dig in the next couple of days to find out if I have on my local the templates and if and how that could be applied.
 
watchpoints don't work on powerpc64le-linux ・ phpdbg ・ #81408
 
 
3 hours later…
7:51 AM
Incorrect JIT code for ADD with a reference to array ・ JIT ・ #81409
 
8:44 AM
morns
 
 
3 hours later…
12:12 PM
@cmb I can see your release announcement of 7.3.30 from 26th Aug but see it missing here php.net/releases can you add?
 
@brzuchal this page is for "old" release, so 7.3.30 have not to be there
 
cmb
right :)
 
7.3.29 was there
 
because 7.3.29 is an old release
 
ok, I didn't know that since releases of 8 are there
 
12:15 PM
7.3.30, 7.4.23 and 8.0.10 are current, so not on this page
 
cmb
7.3.29 should only be there since 7.3.30 had been released
 
ok, got it forgive me I didn't know :D
 
cmb
The page title is "Unsupported Historical Releases" :)
 
Hehe, I haven't read the title "Unsupported" I just type URL in browser and assumed a list of all releases
Anyway, I'm sorry. I've noticed the docker images are available for alpine in version 7.3.30 but for stretch only in 7.3.29
 
cmb
@RemiCollet, mailparse's arginfo.h appears to be generated, but I can't find the stub file.
 
12:23 PM
got the issue, stretch is oldoldstable, the newest is bullseye or buster also have the 7.3.30 in docker image
 
@cmb no arginfo is manually maintained for now on this ext.
 
cmb
ah, okay
 
@cmb btw, you can merge the CI PR on this one, but don't know is something else needed to enabled them (never use that on any of my project)
 
cmb
No, that should work automatically. But maybe you want to check/improve the hacks?
 
@cmb to be honest, I do'nt care of CI ;)
/me rely on his local builds, using real distro (fedora/rhel)
 
cmb
12:29 PM
I find it very useful especially for PRs (and Windows support). :) I'll merge the CI PR.
 
Woop woop seems we can now skip revcheck for a doc-commit o/
 
@cmb abnout the hack, I usually use something like: export TEST_PHP_ARGS="-n -d extension=mbstring.so -d extension=modules/mailparse.so"
this can be simpler, not having to change extension_dir (mbstring in installation path, mailparse in build directory)
and also "php run-tests.php" instead of "make test"
 
cmb
Ah, thanks; I'll check that out! nmake test is quite useful on Windows, though. :)
 
12:45 PM
@cmb btw, I don't understand why HAVE_MBSTRING is not defined in this env.
 
cmb
It is also not defined for me locally.
 
# grep HAVE_MBSTR /usr/include/php/main/php_config.h
#define HAVE_MBSTRING 1
looks strange
in ext/mbstring/config.m4 we have AC_DEFINE([HAVE_MBSTRING],1,[whether to have multibyte string support])
so it should be there
looks like a bug from the binary provider
 
cmb
@RemiCollet will check that as well; and there seems to be a bug in run-tests.php: I need to pass -P, although that should be the default
 
oh yes, I also always use export TEST_PHP_EXECUTABLE=$(which php)
and didn't understand why this is not the default...
 
Incident with Codespaces
 
@Gordon currently not touching main site :P not sure if meta is affected in the same way
 
@NikiC what is the reasoning for deprecating the [new Foo, "Bar::method"] case in particular? too much magic for first hand support? i.e. why would you not instead offer the option to make it usable via $callable() syntax?
 
cmb
@RemiCollet php_config.h has /* #undef HAVE_MBSTRING */; likely they build php without extensions, and do separate phpize builds for the exts; I think this is a valid way to distribute
 
@bwoebi It has questionable usefulness and the precise semantics are unspecified and vary by PHP version.
Things like "what LSB scope does this call use?"
 
2:09 PM
Hey !
 
2:23 PM
@PatrickAllaert 8.1.0RC1 not yet announced ?
 
@cmb How would I go about (preferrably statically) linking zlib into Xdebug on Windows so I can have compression there too? (Like I do for nix at github.com/xdebug/xdebug/blob/master/config.m4#L40-L47 )
 
@RemiCollet Not yet, about to do it now
 
Does anyone know Vincent Pontier and/or does anyone know why the purchase experience for elephpants at elephpant.com requires i) watching at least part of a video before the 'buy' button appears ii) Why the purchase userflow goes through messenger.com and not, you know, just buying stuff?
 
i) it's "cool". ii) shrug
it's a designer designed experience... I suppose
 
@Tiffany but it's fixed. it's safe to go there again. they say no users compromised. I still logged out on all devices and relogged just in case.
 
cmb
2:40 PM
@Derick something like
if (CHECK_LIB("zlib_a.lib", "xdebug", PHP_XDEBUG) &&
	CHECK_HEADER_ADD_INCLUDE("zlib.h", "CFLAGS", "..\\zlib;" + php_usual_include_suspects)
) {
	AC_DEFINE('HAVE_XDEBUG_ZLIB', 1);
}
 
and that's a static link, or dynamic?
 
cmb
that's static (signalled by _a.lib)
PHPOnWindows convention
 
2:57 PM
@NikiC I thought this would be the syntax to specify a LSB scope equivalent to the class of the left hand
 
@PatrickAllaert That seems so ugly to me... Reading the version, we see both "release candidate" and "development version"...
 
Developing the RC?
 
@MicheleLocati It's not for released versions, and to distinguish between RC1 and the intermediate development branch code until RC2 gets released,
 
@PatrickAllaert Thanks for staying on top of things today! My brain isn't functioning properly. :-)
 
Yep, I understand the rationale. But still we read "release candidate" and "snapshot version"... so ugly
 
3:07 PM
Who cares if it's ugly? It's not a pretty marketing website.
 
I'm missing something. What's the "ugly" part?
 
It's ugly that in a version string we read both "release candidate" and "snapshot"
And that's driving me crazy making the version parser of github.com/mlocati/powershell-phpmanager work
 
3:27 PM
@ramsey Feeling better?
 
@PatrickAllaert Much better. Thanks!
 
PHP 8.1.0RC1 has been announced! You can also RT the love (twitter.com/AllaertPatrick/status/1433451150758621185) :-)
 
I can tweet from official_php instead...
just trying to find a good new elephpant picture :-)
there :-)
I should not have tagged myself...
 
3:47 PM
Edit and/or delete and repost?
 
Edit how?!
 
I don't use Twitter much, but I'm sure you can delete and repost instead ^_^
 
Yes, but why would I do that? Then people would see it twice...
 
4:14 PM
@Trowski question regarding how you envision constrain... could it work with finding a node via XPath, like function doStuff (DOMXpath $xpath) constrain (is_object($xpath->query('/xpath/query/')->item(0)))
 maybe
 function doStuff (DOMXPath $xpath)
     constrain (is_object($xpath->query('/xpath/query/')->item(0)),
         !empty($xpath->query('/xpath/query/')->item(0)->textContent))

 though I don't really like using an empty check here, but doesn't seem like it would be possible to do !== ''
 
Yes, any expression using an arg will work. That's a little longer than I may have envisioned. !== '' would work fine there instead of empty.
Maybe && instead of the comma though
Keep it to a single expression.
 
the ->textContent call could probably done as a guard statement within the method, but the first part would be nice to use without a guard ...
 
Why not $xpath->query('/xpath/query/')->item(0)?->textContent)?
 
^ That would work nicely, yeah.
 
how would nullsafe behave in constrain?
 
4:25 PM
Though, because PHP, '0' can be a problem there.
 
(I'm currently on 7.4, so can't use nullsafe :( )
 
@Tiffany Same as anywhere else. constrain could be any expression.
 
🤯
 
constrain($xpath->query('/xpath/query/')->item(0)?->textContent) is all you really need.
Assuming you're fine with '0' failing… Can we change that too?
 
the likelihood of '0' appearing as legitimate customer data seems pretty low ...
but customers regularly prove developers wrong ...
wait, I may be misunderstanding how '0' comes about
 
4:48 PM
@bwoebi Nope, that's not what it does: 3v4l.org/MjSOK
 
Could anyone explain to me the relationship of Steve Wozniak and ecommerce
coz' I just don't get it
 
He's rich.
 
@Crell Not so very sure that's a valid statement any longer
 
5:05 PM
@JRL Hm, interesting thought. What would be the int value of Ordering::Unsortable? It can't be 1, -1, or 0. :-)
 
@Crell 2 ?
 
@NikiC 3v4l.org/G6Q4V for the new case it's true, I did not know about the bare class name case (because only used with object instances, ever)
 
@Girgias Techincally used to be a valid sort return value, until 8.
 
As something unsortable always returns 1 in ordering IIRC so you'd still get the correct behaviour with positive/0.neg
 
Unsortable always returns 1?
 
5:10 PM
@NikiC but obviously as this does not do anything useful (i.e. no static binding), no need to retain that syntax
 
cmb
@Crell NaN :p
 
Has anyone in here set up a pear channel before? I'm curious about binary package capability for PECL. It seems "possible" based on the package.xml but I've never seen it done in practice, so I'm guessing it's under-specified or something. But I didn't really find out any resources on how to set up these channels to practice...
 
@Girgias PHP is so fucking weird.
 
@Crell You're only realising this in 2021?
 
5:17 PM
No, just stating an established fact that is relevant in context.
 
I'm low-key tempted to make a talk called "I hate PHP" of all the dumb shit PHP did or still does
 
You should call it "a fractal of bad design" and then make sure to list all the previously stupid shit that you've changed so it's not so bad
 
Genius, hire this dude
 
@cmb Is a float, not an int, apparently.
 
Yeah
Did you know there are different sorts of NaNs? :D
 
5:21 PM
Reduce PHP_INT_MAX by 1 and then use the previous PHP_INT_MAX as unsortable.
 
@Girgias Computers are so fucking weird.
 
nan nan, nan nan nan nan, heeeey heyyheyyyy, oooahhh.
 
@MarkR is so fucking weird
 
This is not new news ol chap.
What is news: Abba delight fans with new 10-song album and virtual concert O___O
 
@JRL I'm now leaning toward making Ordering a non-backed enum. Does that cause any issues for you, design-wise?
 
5:41 PM
@Crell Why not back with -1, 0, and 1?
I missed this discussion, I guess.
 
@LeviMorrison Because then it's unclear what should back Unsortable.
 
That shouldn't be part of ordering.
Return ?Ordering or something if you want that to be part of it.
 
Apparently, it already is. Just badly.
 
5:56 PM
throw an exception :D
 
6:13 PM
@JRL wiki.php.net/rfc/sorting_enum - For your consideration. (I'm somewhat impartial on Uncomparable vs exception vs whatever.)
 
6:25 PM
@Crell simple trick for remembering the -1, 0, 1: in earlier times you returned $a - $b when sorting … now it's $a <=> $b - for the behavior to hold, if $a > $b, then $a > 0
 
I will no doubt forget that momentarily.
 
All issues have been resolved!
 
@ln-s I'll have to check it out.
 
I think you'll like it
 
JRL
7:10 PM
I was planning on having it unbacked as well @Crell for that reason. NaN was also my thought on how I'd back Uncomparable, but I think it's better to just not back it, especially with the way we are proposing it be used.
RFC looks good. Simple, to the point, avoids extra scope questions.
Besides the inevitable bikeshedding that is, lol.
 
Are there any PHP modules/extensions which build a static library that they link into the module/extension? Everything I've checked builds everything directly into the single module/extension.
 
@Crell I think you should include a function to convert from numeric to enum
 
JRL
@MarkR that would occupy a second global keyword, and also need to be removed if PHP ever fully switched over to the enums from ints though.
or, wait you probably mean ON the enum
 
@JRL I mean a bog standard function that would take a negative, 0 or positive and convert it to an order enum
 
JRL
ah, so not an enum method. do you have an idea of what sort of name you'd expect for such a function?
 
7:20 PM
That wouldn't be a function on the enum?
 
hmmm, fromDifference maybe?
 
JRL
@Trowski yeah, i am much more partial to a function on the enum personally.
@MarkR that would work well for an enum function, but probably not a normal function.
 
OrderEnum::fromInteger() I would think.
Or similar.
 
JRL
Ordering::fromDifference(int $difference) makes sense.
i think fromDifference is more descriptive than fromInteger personally, to remind the dev that they need to subtract them first
 
Wait, subtract them?
 
JRL
7:26 PM
Also @Crell, on the bikeshedding notes, I think I'm partial to Equivalent instead of Equal personally.
@Crell Yeah. Ordering::fromDifference($a - $b) would be the same as Ordering::fromDifference($a <=> $b)
 
If you're talking about essentially emulating from() on an unbacked enum, I suppose we could, though I'm not sure when I'd use it.
 
I don't think difference is a good term there. That's highly specific to the integral domain, but you wouldn't "subtract" strings for comparing ordering, even though the compare result is also an integer.
 
@JRL Potentially more semantically correct, but also longer to type. That hurts the ergonomics.
If we could figure out a backing value for unsortable, we'd get that for free.
 
JRL
Yep, it's a trade off. It's just my 2 cents, I'm not strong willed about it.
 
Again, unsortable has no place in Ordering. Use a nullable ordering e.g. ?Ordering there.
 
7:29 PM
@JRL Difference => Distance ?
 
JRL
@LeviMorrison I understand the argument, but I strongly disagree. The uncomparable state is something that is directly represented inside the engine with ZEND_UNCOMPARABLE and is an actual result that is possible user sort functions now.
i also do not believe that we should be adding more places where null is used for a specific case when we have an enum
that's... like the whole point of enums
 
I strongly disagree with you. I see no way to reconcile.
Maybe<Ordering> would be the type-level encoded thing if you would like, but we don't have generics. null serves this purpose just fine.
Additionally, what the engine does internally does not necessarily have to match what the userland interface does.
Just like we have zend_api that take HashTable instead of zval. It's fine to have another internal representation for working with internals, and in fact it would be nice to avoid the object-based API of the userland enum.
 
JRL
So is the issue that Uncomparable isn't an Order so it doesn't belong on Ordering? or is it the concept of representing Uncomparable at all?
 
There's two related issues here.

1) Technically the sort API already supports "uncomparable", just in a gross and non-obvious way. It should be made clearer, as it will likely be needed more often with __compareTo().
2) Magic constants suck, and that's a gross part of the sorting API right now.

Point 1 could be solved by returning null in addition to ints.
Point 2 could be solved by either a couple of named constants in the engine, or an enum. Since it's a logically closed set, an enum seems like the semantically superior option.
 
8:16 PM
@JRL Oh in that case I like fromDistance.
 
8:29 PM
I agree fromDistance() is a poor name, actually, because you'll basically never be using a straight integer in sorting. If you were, you wouldn't be using a custom comparison.
 
what else are you meant to sort on other than numbers?
 
JRL
Well that's the point of functions like usort() isn't it?
 
Alphabetic strings. Dates. Or product types that contain those things.
 
You might sort a set of objects based on the value of a property etc, but ordering in general implies numbers
 
JRL
ordering implies a sequence i would say
not necessarily numbers
well, it implies ordinal number, but not cardinal numbers
 
8:35 PM
@Crell Those are both based on numbers
 
It's a computer. Everything is based on numbers if you go down far enough. That doesn't mean the user-facing API needs to force you to think of everything as a number.
I'm still not sure when I'd ever use from() on an ordering enum anyway.
Technically if it's not a backed enum we can still use from() if we wanted to, I think. :-)
 
@Crell Because it forces everything into supporting a union, where as if you could just do Order::fromDistance($a - $b) then you don't have to write a horrible double-ternary
 
Double ternary?
I need to see code, because I don't understand what you're saying.
 
$a == $b ? Order::EQUALS : ($a > $b ? Order::LEFT_GREATER : Order::RIGHT_GREATER)
 
That's no different than what you do now with ints. Or... more realistically, I'd just use a spaceship there and be done with it, and that doesn't change.
 
JRL
8:42 PM
that's more a question for the possible future idea of replacing all int sort values with this enum, but that's future scope for this RFC
 
Better to add it at the same time IMHO, that way you get many more years of having it available,
 
JRL
the idea is to introduce the RFC now to:

1. Allow developers to use the closed set where it makes sense.
2. Provide the foundation for a future version of PHP to deprecate and/or remove the int value representation.
hmmm. you think that just removing all int sorts now is preferrable? go to the enum all at once?
 
int|Order for compare functions seems reasonable, no?
 
I don't think that's realistic.
@Trowski That's what I'm targeting.
 
JRL
i mean, i personally would be all for that, but I also find it unlikely it would pass a vote, and it would also obviously be a more disruptive change
 
8:45 PM
That makes the most sense IMO. Don't break functions returning int just because.
 
The alternative is a tiny user-space package with a couple of int constants in it, but that seems wasteful if we can do it in core better.
 
@JRL Nah, but let's say you add the helper to convert distance to enum now, but 5 years from now you decide you do want to remove the int version, you've got 5 years of supported versions that can use it, meaning there will be far less occurances of the int style when you come to deprecate it. Vs if you introduce it only at the point of deprecation.
Statics can't be polyfilled (this was part of the argument against static methods as part of php\std
 
JRL
@MarkR oh you're speaking in reference to providing the from() method
 
@JRL I am.
 
JRL
that makes more sense :)
 
8:53 PM
I'm not against a from() method. It just seems odd to add it on a non-backed enum to essentially emulate a backed enum. :-) But then there's the silliness around Uncompariable, which makes just making it a backed enum more difficult.
I suppose we could just do PHP_MAX_INT, since it's unlikely anyone is using that already? :-) Although I don't know if that would break the work Nikita did that made non -1/0/1 returns an error already.
 
JRL
In my operator overload RFC, I'm compressing all positive ints to 1, and all negative ints to -1 for __compareTo
though if this enum existed i'd obviously just require the function to return the enum
Uncomparable is extremely useful in situations where something like Matrix > Decimal happens.
which, to be clear, can already happen with user sort functions outside of my operator overload RFC
for such a situation, null is a bad choice IMO because null will get juggled to bool(false) if cast to an bool
implying a definitive answer if the result is naively cast
which im 100% certain PHP devs will do
 
Will they really be doing that inside a usort callback?
 
JRL
probably not no, but the enum will see use in other contexts
 
9:09 PM
Where?
 
 
1 hour later…
10:32 PM
How can I go about flagging a message in the transcript? I want to flag an old message of mine that's pretty terrible in hindsight, and I absolutely deserve the penalty associated with having a flagged message deleted.
 
10:46 PM
@Tiffany 'flag for moderator' and say 'i regret this message' or similar? or just leave it...
 
11:28 PM
I don't have the option to flag it because it's in transcript, at least when I checked earlier from desktop.
 

« first day (3974 days earlier)      last day (973 days later) »