Spent the last little bit trying to create an algorithms library that's been designed with named parameters to try to create things that are more English-like.
hi; lets say I create an OOP blog / forum / tube, or anything else; is object creation (how I create objects / divide a script into objects) based on the MVC (model-view-controller)?
@MarkR From what I see they are all fixed, (except Zip because it's intended behaviour which was not documented) and it seems more to be a repo as to how he went about finding those vulnerabilities
@AndyRogers I would if I understood the question. MVC is a way to structure your code, you can certainly build a blog with OOP without following the MVC pattern.
@Girgias Good to know, in my company there's a running gag that anybody who touches a system is the new specialist ^^ Can you help me with my JIT problem please? :D
@IluTov Don't think so lol, it was just that casts to boolean where segfaulting so I basically reverted the change which made the return value of a function from int to bool, so I didn't actually do anything on the JIT :p
@Girgias I'm just joking :) I'm one of the oldest (as in the longest employed) employees in the company and my boss just claims I know stuff that I've literally touched once 5 years ago :D
@IluTov Haha, I mean I've got a good memory for stuff I've seen/done. Always disturbed my friends when I could tell them how to get a weird Vista point in GW2 just by looking at where they are on the world map even if I'm nowhere near them xD
@Derick (and @Andrea as she participated on the Reddit thread). Re: ISO8601 DateTime constant it seems the constant is not up to spec anymore because of the mix of Basic and Extended format notation (seehttps://www.reddit.com/r/lolphp/comments/idui3p/breakingtofix_in_array_for_php8_ok_breakingtofix/g2cjz2g for context)
@LeviMorrison Yeah, but I should say that this is pretty much a purely technical limitation, which can be lifted in the future. It's forbidden for similar reasons as positional arguments are not allowed after unpacks.
hey, where can I learn about object creation when I write an OOP script (how do I divide that into objects)?
blog / forum / tube script, or anything else; OOP; so this will be objects; where can I learn about how do I divide these (any script) into objects; I dont understand it yet
I ended up not finishing my streams conversion because I don't want all that work to rot on the branch. But it signposted a few good ideas for when I pick it back up.
@AndyRogers just start building something. Don't worry so much about the theory, and stop thinking that you have to fully understand something before you can make something useful.
And because it's been a problem in the past, speaking as a room owner, you're not allowed to ask rambling open ended questions in here. Just go build something, and you can ask specific questions, not "what is object creation".
@AndyRogers You'll learn the most building things and looking at what other people have built. If you wanna understand how to structure code, look at how everybody else does it. Look at good Symfony/Laravel projects. There's no book that will teach you everything. You'll need to get your hands dirty and be willing to make mistakes eventually.
We've got a new rule; no-one is allowed to indulge your OCD behaviour. Everyone is going to just tell you to get and talk to your doctor about your OCD.
@Derick Many of the array*() functions right now have utterly absurd param names that don't make any sense with named params. I'm trying to clean those up (because it is low hanging fruit I can actually reach). Commence naming things discussion!
Disagree. s/$rest/$arrayN/ I don't know about, but just trying to read the docs $array1/$array2 is not helpful. array/exclude makes much more sense from a user POV, both for docs and for named params.
Furthermore, should we even require interpolation to be prefixed by #? If we already have a string-wide prefix, having to prefix every interpolation could be annoying. ($"#{Foo::bar()}" vs $"{Foo::bar()}"). Question is which are more common, string interpolations or literal braces {?
You also can't use both variadics and named parameters at the call site, which I think we should permit. Roughly, the order should be all positional parameters, then all named parameters, then any variadics. I think.
So far I like named parameters; the combo of variadics and named args was the only thing I was concerned about during RFC window, and so far it's still my only complaint.
> implode() can, for historical reasons, accept its parameters in either order. For consistency with explode(), however, it is deprecated not to use the documented order of arguments.
I wonder if implode/join can even use named ags! Time to find out.
Hey, weird question, is there a way to unload a class from memory? I've created a script to generate random classes on the fly, with random names and random properties. I'm generating about 10k at a time, but I'm running into namespace collisions. Any thoughts on how to avoid that? I don't care if they have the same name. They aren't meant to be used for anything, and this is a single script to generate data.
That should be done very quick, then. I don't think that we can change parameter names after 8.0.0beta3 on a larger scale (and even now is pretty late) :(
No, that was for php. My question is, why does a routes cache involve a 800kB base64 encoded string. Or rather, do I dare even consider why it would involve that? Could I bear the answer?
@MateKocsis I wouldn't know (may just not be supported?), but I wouldn't want to convert them in the first place, because it's preferable to remove these dual APIs in the long run, IMHO.