Really curious what is behind the @Revolut outage. I cannot even login in their app.
Almost 30 sub-systems partially broken. I can bet, that problem of such a size only possible due to human errors and lack of ITGC processes in place. This can be one of certificates or private key re-issued or untrusted because of legal entities split.
Hmm, another possible scenario is outage of GCP: https://t.co/ZP373ub8BE where Europe-west-2 region in London is disrupted in all services. Still, why don’t you have cross-regional redundancy/sharding to keep services operational?
Reified #generics in #PHP, in userland, with no php-src patch. Here's how z-engine makes it possible.
Box::of('int') doesn't return a wrapper or a validator. It returns a real class, Box<int>, registered in the engine's class table. The Zend Engine itself throws the TypeError, the same one a hand-written class would throw.
How it works:
Z-engine reaches the engine's C structures from plain PHP through FFI. Its ClassSpecializer deep-clones the template's zend_class_entry under a new name and rewrites the zend_type of every property, parameter and return type. The compiled method bodies aren't copied. They're shared through the engine's own op_array refcount.
That's why the memory numbers are interesting. A 32-method specialization costs 34,448 bytes whether each method has 4 statements or 200, identical to the byte. Generating and compiling the equivalent concrete class costs 22,480 and 399,312 bytes. "Monomorphization costs too much memory" is the usual argument against generics in core, and now there are real numbers to discuss.
What surprised me:
• Rewriting a type isn't the same as enforcing it. Property writes read zend_property_info and return checks read arg_info. But plain parameter checks use a type mask the compiler cached in the RECV opcode, so that mask has to be patched too. • A specialization is a sibling of its template, not a subclass: $intBox instanceof Box is false. Type-hint an interface instead. • The name Box<int> is deliberate. No PHP source can declare a class with < in it, so it can never collide with a real class, and it still reads well in stack traces.
Cost: creating a specialization takes ~220µs plus ~150µs per method, and fetching an existing one takes ~2µs. Method calls run at parity with hand-written classes. The one exception is class-typed property writes, which cost about 2x.
It runs on PHP 8.4 and 8.5, plus 8.6 beta. There's also a PHPStan extension, and a test suite that runs on --enable-debug builds so memory corruption surfaces as an assertion failure.
It's experimental, so not for production, but it shows PHP's engine is far more flexible than its syntax.
https://t.co/JLK4r7vdox https://t.co/LWA4pwYZeD
#PHP #Generics #PHPInternals
After several fixes of Tailcall VM for PHP8.5/8.6, I’ve managed to receive green CI pipeline for a new version of my Z-Engine for upcoming PHP8.6!
And framework has received an ability to preserve original method/function code during the redefinition of existing PHP class methods https://t.co/wHM5IlcSC2. Useful for AOP or for long-running process managers - just swap one PHP method with another one.
@nicksdot@lubosdz I’m dreaming that with https://t.co/Rhihipa2Rn it will be possible to install extensions via composer just like normal libraries ) And to organize a marketplace for extensions ☺️
Why is gold yellow? 🪙
Surprisingly, Einstein has something to do with it.
Gold has 79 protons, so its inner electrons move fast enough for relativistic effects to matter.
Relativity shifts gold’s electron energy levels, making it absorb blue light more strongly.
The remaining reflected light looks yellow.
Without these relativistic effects, gold would look much more like silver.
So the color of gold is, quite literally, a visible consequence of Einstein’s relativity. ✨
goaop/parser-reflection 5.0.0 is out 🚀
Early release with PHP 8.6 reflection parity — before PHP 8.6 even ships:
✅ partial function application
✅ readonly property defaults
✅ isReadable() / isWritable()
✅ parameter doc comments
All static. No class loading.
https://t.co/LIfBoJeQB9
While this in Beta, some features may be working non-optimal. Cursor support will be added soon, just the matter of whitelisting callbacks from security PoV.
Thing that I’m proud of: https://t.co/DdpH1EJCHG
We have launched the official TradingView MCP server for paid subscriptions! At the price of just one lunch you will have access to high-quality financial data, which can be used by agents to make proper decisions!
@VotrubaT I wasn’t able to do it in remote sessions, because Claude cloud sandbox has some rules, preventing agent from pushing tags. Also, GitHub release can be done only manually for now, no MCP tool for this is available. Or I wasn’t checking deeply yet the problem.
For terminal lovers: do you agree that AI agents will start soon register themselves as default shells in OS? I’m observing that I’m opening terminal just to launch my favorite agent in working directory and then continue fully inside agent terminals. @bcherny
PS sometimes I still need git tagging/misc calls, which are not exposed as MCP tools yet.
#PHP 8.6 turns on three session settings that should have been default 20 years ago. 🔐
session.use_strict_mode goes from 0 to 1, so the engine REFUSES a session ID it never issued. That flag kills session fixation.
session.cookie_httponly goes to 1 and session.cookie_samesite becomes "Lax".
RFC session_security_defaults, by Jorg Adam Sowa. Custom handler? Implement validateId().