Skip to content

Instantly share code, notes, and snippets.

View simPod's full-sized avatar
💥
Trying to BC break your OSS

Simon Podlipsky simPod

💥
Trying to BC break your OSS
View GitHub Profile
@simPod
simPod / EnumHandler.php
Last active June 17, 2020 05:57
WIP: JMS Serializer EnumHandler for myclabs/php-enum
<?php
declare(strict_types=1);
namespace NS;
use NS\Enum;
use NS\Exception\FileDoesntContainClassDefinition;
use NS\Exception\NotSupported;
use NS\PathnameToClass;
@simPod
simPod / pcntl_waitpid.php
Last active November 10, 2019 14:53
pcntl_waitpid() bug on 7.3 + ext-grpc macos
<?php
declare(strict_types=1);
$childProcs = [];
for ($batch = 0; $batch < 1; $batch++) {
$pid = pcntl_fork();
if ($pid === -1) {
throw new RuntimeException('Failed to create child process');
SELECT sml.schemaname,
sml.tablename,
(sml.reltuples)::bigint AS reltuples,
(sml.relpages)::bigint AS relpages,
sml.otta,
round(
CASE
WHEN (sml.otta = (0)::double precision) THEN 0.0
ELSE ((sml.relpages)::numeric / (sml.otta)::numeric)
END, 1) AS tbloat,
@simPod
simPod / SassMeister-input.scss
Created October 20, 2014 13:33
Generated by SassMeister.com.
// ----
// Sass (v3.3.14)
// Compass (v1.0.1)
// ----
@function z($layers...) {
@warn "`#{inspect($layers...)}`";
}
.test {