« first day (3034 days earlier)      last day (2140 days later) » 

MGE
MGE
15:03
Hello, I've this:
<?php
namespace Controllers\errors;
use Controller;
class notfound extends Controller{
	function __construct() {

	}
	public function start($args) {
		echo 'The page you are looking for does not exist.';
		$search = new Models\search\people;
	}
}
Sam
Sam
Hi, when hosting a web application with a decoupled front end and back end (back end is formed as RESTful api's... should I have two seperate domains? I'm not really sure how to do it
MGE
MGE
the problem is that Im using spl_autoload_register and this instance is called in Controllers\errors, so instead of loading.. Models/search... it call to Controllers\errors\Models\search\people
how can I solve this?
I just saw phpstan has been waiting for a year for phpstorm support ... this doesn't fill me with confidence ...
they appear to have their own (intellij's) static analysis engine ...
@JoeWatkins regarding what?
@JoeWatkins they do, yeah
@MGE Read the "Basics" section of namespaces in the manual
15:07
@bwoebi I mean today, what other options are there ? or are you saying in case some better solution comes along that doesn't exist today ?
@JoeWatkins Options regarding what? debugging the jit? yeah can't think of anything else
@bwoebi so what do people want from them with regard to phpstan ? just a way to run the commands and see output from the ide ? because I can do that in a couple of hours I reckon, I can't do the pcov thing because it requires too much that is closed source ...
@JoeWatkins there isnt even a phpstorm plugin for watching a checkstyle.xml file and automatically applying this as errors, this would give instant support for all tools
@bwoebi I thought you meant better than dynasm, for the impl itself ...
@JoeWatkins ah - well ... I think dynasm is pretty great and simple for what it has to do...
@JoeWatkins I have absolutely no idea
MGE
MGE
15:10
@PeeHaa thanks, fixed with \
@beberlei that ... can't be hard ...
who has some java, I promise I won't tell anyone ? we could r11 this, I don't mind doing the initial work on it at all, but not interested in anything but writing the code really ... so releases, packaging, testing, lasing, all the other stuff, I don't have time or will power for ...
also, I have 27 days left of phpstorm ...
@JoeWatkins Not using the php-src licence?
I don't know how
hmm, it let me sign in with github before, how do I sign in here ?
@JoeWatkins is there actually a problem with making weakrefs serializable?
failed summary – #77570
I'm not sure of the behaviour of unserializing ...
I mean you can't reasonably do that, can you ? so it seemed to make sense to disallow serializing ...
@JoeWatkins why not tho? I'm not sure I see the problem
When you serialize, you of course also have to serialize the object that you're referencing
Ah, I guess I see what you mean
You are thinking about the case where the referenced object is not part of the serialized value graph?
15:27
I thought you were trying to trick me there ...
yes, it's not a weakref anymore
I think it should still be possible
You'd either get back a weakref to an object somewhere else in your serialized value
or you get a dead weakref, if the weakref is the only user
ok, will test
DateInterval timezone bug – #77571
But now I'm not sure anymore if this is a good idea...
Maybe it isn't...
it seemed to be worth avoiding to me
we could look at what java does, I'm not sure ?
15:30
that sounds sensible
ok will do that
@JoeWatkins ok, looks like it's not serializable in java
right, well that's sound justification
but, what is the actual intention when you have a weakref in a graph, is it to serialize that reference, or to serialize the object to which is refers ?
we could allow that, but it would be a different graph unserialized, so it would also be strange ...
I think this is best avoided
ok
you can easily convince me with words, if I'm wrong ?
15:37
@JoeWatkins nah, that's definitely a no-go
It would have to stay a weak-ref
yeah I thought so too
It just seems easy to shoot yourself in the foot with this
PHP: making it easy to shoot your feet off since 1995 (tm)
3
I'll answer on internals
okay, didn't even see it, people coming at me from all sides today, thanks ...
Wes
Wes
15:43
oh well, maybe it's a good thing you are revoking some people's ability to vote twitter.com/CalEvans/status/1092808703017922560 ¯\_(ツ)_/¯
In this image, is "API Getway" a PHP script which determines which service is called?
we love you @Wes
Wes
Wes
lol
@Shafizadeh Gateway
yes dat ^
Wes
Wes
15:46
ironic love?
@JoeWatkins I'm kind of oscillating here, maybe it makes sense after all???
gotta love it when a vendor writes code that has to be rewritten... having them rewrite it at this point is out of scope of the contract
@NikiC I agree with the guy that it's unfortunate, but not unfortunate enough we should change our minds, it doesn't seem to make good sense to allow it because of what that may lead too ...
but hey, if you think about it a while, and can reason a way for it to make sense, I'll listen obviously ...
@Wes no ...
15:54
@Wes I'm curious why he wants people to vote no
because it sounds cool to say that^
Wes
Wes
> We are all adults
and then
"jump on the negative bandwagon with me against (what looks like) this newcomer"
Wes
Wes
> I just asked those with karma to vote no.
lol yeah
I keep forgetting to check the "remember me" when I log into twitter at work
15:57
@JoeWatkins Another use case of a jit map to opline would be profiling at a higher level … nobody wants to profile the bare asm/machine code. While still profiting of the jit speeds to see realtime impact
Wes
Wes
@Tiffany leave it, it's not worth the time
no, I'm curious
I'm not trying to pick a fight
@Tiffany Does that ever not happen?
jit would even allow for actual hardware profiling (performance counters) sometime in future ... @JoeWatkins
@Allenph in my anecdotal experience: no, unless they encrypt it or something.
16:00
@bwoebi I was thinking along these lines earlier today talking to @beberlei, but trying to figure out a way to map ... just in time ... with hooks and such, but yeah, agree ...
@JoeWatkins I doubt you can map that just in time ... you'll need to do it upon generation, possibly a runtime flag…
even if you could, it would be better not to have too ...
externals.io/message/103513 this is a nice one, but scary knowing that one legacy codebase I have to upgrade at some point has hundreds of @ ...
either way... the entire thing would get a rewrite on a lot of parts by then
@bwoebi yes jit to opline would be great!
although, without getting access to your profiler while within the jit, no chance to read it
16:17
\o
@NikiC now I flat disagree with him, giving him another way to shoot himself in the foot doesn't solve his "fundamental problem" ... if you want to call it a fundamental problem, then it's a problem whatever, we would only be creating another ... it will be extremely surprising if what you unserialize is not the same shape as that which you serialized and that's the bottom line, there is no way to avoid that that I can see while retaining the behaviour of a weakref ...
@beberlei uh why? it would just generate a pointer to the op_array map or such to the hit map as well … and the hardware event can read that
I think, his profiler is implemented as a hook on execute_ex, so it's not entered he's saying ....
ah okay
then obviously useless.
zend used to be the lowest level we had to work out, we may just have to get used to the idea of working at layers beneath it ...and figure out ways to do that ...
maybe there is a way to generalize this here to allow writing opcodes for this kind of stuff directly into the cache, which are then also jitted with the original code itself: github.com/GoogleCloudPlatform/…
16:31
I thought about that too, it doesn't jit functions with uops in them, probably same for ext ops
we could have a purpose built instr, but in that case why not just jit uops or ext ops ... I don't know what the reason is for that ... I wouldn't want to guess what they are either ...
@Wes that's... urgh. If you're going to encourage RFC voting participation, at least try to encourage voters to carefully consider the options and vote accordingly. What the system doesn't need is "Vote Yes because I say so" and "Vote No because I say so" campaigning on Twitter.
yeah, pretty terrible ... but you know, a lot of crap goes on twitter that you could loose your shit about ... probably best to ignore it ... also, I can't imagine anyone is going to vote no because cal told them too ...
@JoeWatkins well, we probably can get user ops as well in jit … just not yet
I think this probably solves the problems both @beberlei and I have ... it's not what we do today in some cases, but it will work ...
Wes
Wes
cal is a nice guy tho, it's just hard to notice how dangerous it is doing what he's doing
16:41
extremely nice chap, I just trust people to be capable of independent thought ... so it matters little what people say on twitter or reddit or any other shit show ....
for it to have an effect on anything, people would need to actually think "I'm going to vote no because someone on twitter said I should" ... seems pretty unlikely ...
Wes
Wes
well, i am sure it happened already
@JoeWatkins I'm sure it has happened already, hopefully not enough to have any meaningful impact on any particular RFC vote
shit, can one of you lend me your foil hat ?
Wes
Wes
lol
i remind of the scalar type hint rfc vote, with i think about 150 votes. pretty sure a lot of the votes have been "hey buddy, you have vote access, do the right thing here please"
Wes
Wes
16:46
pretty sad :(
there might be some sheep in the crowd of internals voters ... but in general this sort of game can't effect anything ... and I'm definitely a wolf ... rawr ...
I think that this shot down the RFC as it was originally for 7.2 twitter.com/nicolasgrekas/status/872157453865058304 . In the end, it was probably wise to postpone, but I'm pretty sure that had influence in the first vote
On the bright side, if it encourages more people to look at the RFCs and vote then that's great. It's not a very big pool of people who regularly vote. [Citation needed]
well voting IS politics, so every political maneuver is going to happen
this chat room is some form of collusion wrt voting as well :)
@beberlei nah, we often enough have differing votes
16:51
people here frequently disagree, and encourage voting regardless
just happens sometimes that we tell ofthers to vote as well
most of us wear sensible hats :)
Wes
Wes
they enjoy disagreeing with me especially :D
no we don't!
Wes
Wes
lol
in unrelated news i just got the 7.2+ polyfill for co/contra variance working
16:53
it's okay, I fixed it
You surely don't want anything less from your friends and followers than for them to exercise independent thought and reason with regard to every RFC, let's stop pretending it's okay to run twitter campaigns to get anyone to vote *either* way on anything. #php #rfc
Wes
Wes
a thing nobody should use, obviously
what, twitter?
@beberlei seriously, we don't do that, we may work on patches together and in those cases, the authors of a patch are obviously in some sort of collusion, but we are independent actors most of the time ...
there are some pretty lively arguments about them in here sometimes though :-P
Wes
Wes
true that. hey dave, how are you?
16:57
I suspect there's probably a tendency for RFCs authored by #11 regulars to get a higher-than-average number of "yes" votes from other room regulars, but that's more as a consequence of collaboration than collusion
@Wes been better, been worse :-P
not awesome but still alive
(a little better than that ^)
@JoeWatkins i didnt want to accuse, more a joke
@beberlei Collaboration (hopefully) leads to more consensus, but as Bob pointed out we sometimes disagree anyway.
we actually take this quite seriously, we spend most of every day discussing the details of everything, but there's no sense in which we'll vote for something we disagree with just because we consider that person a friend ...
well that gets said rather a lot, and it's not in jest, and it's not true ...
Wes
Wes
@DaveRandom cmon <3 make sure to be in shape for the next php twitter drama
if you work on stuff a lot, then your opinions align more easily as you begin to understand each others vision and work, so its a pretty natural process, and what makes teams much better if they work together for a long amount of time.
Wes
Wes
17:05
the chat is actually very important, it's much easier to communicate and find agreement in here than twitter or the mailing list... in fact i think php would be much better just by moving the mailing list to a chat room
@Ekin it would only affect errors that are already terminating requests, not those that just give warning notices. I think.
@Wes I disagree
@beberlei I'm glad to hear you say that ... I think this to be the most healthy window into internals that exists and like that we more or less built it ourselves, that it happens to exist on stackoverflow is nothing more than happenstance ...
This chat room works so well because people aren't being toxic … really nobody from in here is really toxic …
17:09
@beberlei and also when people work together, they are usually trying to solve the same set of problems. This leads to people thinking the same set of problems are the important ones that a language should address, which leads to thinking the same set of features are important.
> You tried to create a new JetBrains Account, but we found an existing account linked with [email protected].
this is a strange puzzle ... I'm pretty sure I don't have a password, but signed in from github
scratch that ... I have a password
:-D
if anyone wants to mock up a ux for configuration of checkstyle plugin, I'm extremely awful at ux, but can copy ... or I'll just do it myself if no one done that in a few days ... but it will be worse if I'm left to my own devices ...
17:29
@Wes I have very specifically not been looking at either twitter or internals (or news in general) for the sake of my own sanity :-P
Wes
Wes
:P
tbf you can just set your phone wallpaper to "tl;dr it's all terrible" and it will be about the same end result with much less effort
@bwoebi this sounds toxic
17:52
not sure how does that sound toxic... did you mean like britney spears - toxic? :-P
@Wes What's missing from most chats is a nested tree view
(Like Reddit's/Google Groups', etc)
SO has a reply to which is sorta-kinda similar
Slack has full blown threads
But it's hard to follow a discussion (not to mention keep a record of) in a chat, especially one that's not 100% dedicated to the subject, and is heavily moderated to keep the conversation from being derailed by off-topic.
@rtheunissen my knee-jerk reaction is to make it immutable, which answers those and many other questions, but I don't know if that's a lazy cop-out
Wes
Wes
@Ekin took me years to get rid of that earworm and now it's back noooooo :B
sorry ^^,
anybody here ever used Group Use Declarations or saw it used in the wild?
18:07
yes
18:17
Also yes, and it made the code really hard to read....
@ircmaxell like one time or like continously?
@Andreas What is your actual question?
just wanted to find out if there are actual supporters / fans of Group Use Declarations out there or I'm the only one hating it. I always add a phpcs rule to forbid them on CI.
imo, readability of that feature is extremely poor.
You are definitely not the only one thinking that makes things worse when it comes to readabillity
there are a few people who like them.. I'm not one of them, but they also don't bug me too much
18:24
@Andreas agreed.
Other than method overloading can anyone suggest some things that keep coming up on internals, as ideas that need a lot of work before being implemented?
I'm going to attempt to document them externally to emails....
generics
oh yeah.
civility
if this is a frequently-requested-changes thing, normalizing the std lib (function names, arg order, etc.)
18:27
and enums....
@Danack Process Overwhelming
18:46
@StatikStasis ?
@Danack Weak attempt at a joke. Process is a synonym for method; overwhelming synonym for overloading... concealing my attempt at suggesting something you stated you did not need.
18:58
@Paul my thinking is immutable also, but copy only if the container's refcount is > 1
If you push 50 values into a list, you shouldn't need to create 50 objects.
Which is what got me on the copy-on-write track.
19:11
@Wes The easy fix for your RFC is to remove void from PHPUnit.
@StatikStasis Power overwhelming ... related youtube.com/watch?v=HzccCLaLMmw
@Tiffany =D
hour and a half in podcast, probably managed to avoid talking about a certain debugger, I think ... and host promised to edit out any slips ...
@JoeWatkins pcov or xdebug?
Hi I'm Joe... 'XDEBUG SUCKS' Watkins. Nice to be here.
19:17
the second thing
which is...?
a certain debugger ...
you know you're not doing me any favours with these jokes ...
c'mon, say it... SAY IT!
this chat is indexed on google
Sorry, I'm in a jovial mood what can I say.
19:18
ever googled for software you wrote ?
May 28 '18 at 5:52, by Joe Watkins
or xdebug
So I will live on forever!?! Awesome!
yeah well I just don't want to mention it in certain lights/conversations ... I can say it's name, it's not fucking voldemort ...
If I could google for software I wrote and there were results I would be pretty happy actually... well... I would be if it were good software.
heh
Sep 4 '14 at 14:34, by Joe Watkins
I don't xdebug
19:21
I was wondering if you ever worried about Z peering in here or a Z sockpuppet to read your convos but that doesn't seem to be a concern.
tend to use z now, for that reason ...
lol...
Sep 4 '14 at 14:35, by Alma Do
@JoeWatkins more funny, if you write "I'd rather write my own debugger" (which you did)
Ah- did something happen or just for future proofing?
There- fixed mine.
these conversations that you're dragging up, are precisely the reason I don't want to talk about it anymore ... they have been a source of friction, because they were found ... it's taken years to be civil with d, and I want it to stay that way, for as long as possible, because it makes my life easier ...
Makes sense.
19:25
and I sympathise with him, he's been at that project for ~14 years, that's longer than my oldest child has been alive, it's a lifetime ... but it isn't going to stop me writing stuff ...
@JoeWatkins sorry
I don't need to attack anything or anyone, I'm only interested in writing code, nothing else whatever ...
He's a lover not a fighter.
@JoeWatkins Yes... but sometimes the longer you have been on a project the more susceptible you are to stifle innovation and change. It's easy to get comfortable so it's good to have these debates and conversations come up as they have.
let's just move on ... we can observe that some things are better than other things and choose our things without attacking anything or anyone, please let's just do that ...
and if we do talk about certain things, I'm totally fine with that, so long as it won't turn up on google ...
or in someone blog post, or on reddit
19:31
if I do rfcy bits for partial application is anyone interested in doing codey bits? I think it's gonna touch more things than I want to learn at once to implement it
you want bob to do it
and if bob says he wants me to start, then I'll make a start ... but he should finish ...
I want whoever is interested, if anyone, to do it
@StatikStasis The IKEA effect. > We ascribe more affection (and hence more value) to things that we have labored over.
@Paul what's it about?
(-‿•)
19:34
@Paul I'm happy to help but it's been a while since I done a really good patch for zend, so I'd rather bob done it ...
@Fabor Yep. Also reminds me of the Endowment Effect found in Behavioral Economics.
he mostly ends up finishing my work anyway ... which is totally cool, so long as it gets done somehow ...
@Tiffany make $foo42 = foo(42, ?); equivalent to $foo42 = function($n) {return foo(42, $n);};
@Paul you don't happen to have a link to any of the explanations Rasmus has given about why some of them are named like they are?
@Danack I do not.
19:36
@Fabor Endowmen Effect is where we assign more value to things we own. Ex. We find a $1,000 card in our attic. We keep it and frame it. However if we saw the card in the store for $1,000 we would never consider buying it... even though both scenarios involve the same question- we answer them differently depending on whether we own it or not; assign more value to what we own.
@bwoebi gonna do this thing ?
@JoeWatkins okay, I'll write up the rfc anyway and see if anyone jumps in
we'll jump in, it's r11 :)
@Andreas I disagree, I find if you're doing a lot of imports that hurts readability. And would rather group them if I can to make it nicer...
19:39
*Endowment... too late to change.
@salathe heh, I didn't even look to see if one was around
the pipe operator was widely hated iirc, so that would be the first thing to ditch from that rfc ...
I'm sure levi won't mind, he's got other patches going on right now and there was never an impl, although I remember talking about it I think ...
@ircmaxell Who reads the imports? Mostly writing Java currently and they're always folded anyway.
@kelunik you're .... not supposed to admit that ...
:)
@kelunik on a more serious note, there's an idea floating around the room to do a checkstyle plugin for phpstorm, any interest in that ?
@JoeWatkins ditch that future scope, change the placeholder (? retains all bc), specify behavior for optionals/variadics/extra-args... he's got a good start but it needs work, yeah
19:44
> Terms like "recvfrom", "getenv" and yes,
"strlen" are well-established names that should not be split up into
"recv_from", "get_env" and "str_len" due to some sort of arbitrary
consistency/purity idea any more than I should have my name changed to
Ras_mus.
So - Ras_mus it is.
5
@Paul I don't think it super hard actually, but I'm probably not thinking of everything right now ...
it's not hard, just needs to be written down
@kelunik do you frequenetly work with different classes with the same name? (in different namespaces)?
oh, I didn't eat yet today, some sort of chicken seems appropriate, lata all ...
@JoeWatkins Checkstyle? I think PHPStorm recently started supporting php-cs-fixer, no?
19:51
@kelunik I'm totally clueless, @beberlei said there wasn't a checkstyle plugin, and phpstan isn't supported and has been waiting years ... and checkstyle seemed like a good way of supporting many tools ...
yes they did
@ircmaxell It happens, yes, e.g. multiple User classes, etc., but usually the context is enough so you don't have to look at the imports. If I want to know which one, I mostly Ctrl + Click it.
chicken
Just opened youtrack.jetbrains.com/issue/WI-45261, it's a thing "preventing" me from using typed properties right now. /cc @NikiC :P
20:06
@JoeWatkins I have php-code-sniffer set up as an inspection
that's been very useful
hmm... now I am hungry.
I went to the gym today... I think I can eat unhealthy guilt-free.
20:38
@JoeWatkins do what? the placeholder thing?
@rtheunissen Other than being anemic, any criticism of this work?
It needs some form of a Dictionary, but I'm unsure how to deal with the details.
In the past I've taken two callables in the constructor, one for hashing and one for comparison when there are collisions.
Okay, seriously, we should just remove object casting: php.net/manual/en/…
That behavior with scalar is just... wow.
hey @Levi, I was just writing up something very similar to wiki.php.net/rfc/partial_function_application (though using ? instead of _ and specifying more of the behavior) .. do you mind if I edit what you've got (after review, I'm doing it in a gist at the moment) or would you rather I publish it separately?
Go ahead and edit it.
I don't think _ will work anyway, thanks to it being an alias to gettext.
I would prefer _ because there are languages that do that already.
One thing I would probably recommend is permitting ... too e.g. foo(?, $x, $y, ...).
? shouldn't conflict with anything, as far as I can tell, also xquery uses it for partials so precedent
20:51
@Paul also much better than _
@rtheunissen Ha, found my first disagreement on line 3 :)
I liked your experimental branch to you a few days ago asking "these ones?" I believe. Will read recent commits.
Do not consider naming at all in that gist by the way.
@LeviMorrison I'll keep that in mind.. I've an idea for ? with variadics, but I'm having a hard time articulating it - which means I may actually need to rethink it
Or hierarchy as well for that matter. It's just a scribble of a theory that I'd like to explore a bit further.
@rtheunissen I'm not really following the laziness for set. Can you explain why'd you want a lazy set at all?
Specifically, it's lazy about what?
20:53
$set->filter()->map()->first() should only call the callbacks of filter and map once.
The values it contains.
@Paul Also, don't forget to handle by-reference parameters.
@rtheunissen What does map() return? Iterator? Set?
@LeviMorrison yeah, I snagged your example for that.. it covered it better than my original
An iterator that is also a Set
@Paul Wondering if foo("bar", ?, ?) will also be a thing?
Because it returns a new instance of itself using the MapIterator on itself.
20:56
@NikiC it will, yes. why?
I don't know if that makes sense or would work at all though.
To userland, it returns a Set just like an eager implementation would.
Except that it does not evaluate until it has to.
@rtheunissen I will think about this more, but I don't like it.
@Paul Just wondering
@NikiC it'll be: function($a, $b) {return foo("bar", $a, $b);} (though the param names will come from foo's definition)
@LeviMorrison I did not either, at first. See kotlinlang.org/api/latest/jvm/stdlib/kotlin.sequences/…
20:59
@Paul But I'm assuming that there will be no $a + ? or something else that's not strictly a func arg binding?
MGE
MGE
Hello, I have a problem with namespaces and PDO
it try to load directly from my classes folder
everything is passed through from the definition to the closure - param names, type declarations, default values
MGE
MGE
namespace App;
use \PDO;

« first day (3034 days earlier)      last day (2140 days later) »