- GET
/source
change POST to GET: https://www.w3.org/TR/webdriver/#getting-page-source - POST
/element/:uuid/value
. Rename to/element/:uuid/sendKeys
https://www.w3.org/TR/webdriver/#dfn-element-send-keys - GET
/window/:uuid/size
. Rename to/window/size
. - GET/POST
/orientation
. Move to vendor extension (e.g./wda/orentation
)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class NestedFunctions | |
{ | |
public function fn1() | |
{ | |
function nested_fn() { echo 'yay' . "\n"; } | |
nested_fn(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# switch to dvorak, set key repeat etc | |
/home/alexander/.fixkb | |
# Add local fonts | |
xset fp+ /usr/share/fonts/local & | |
## Gnome keyring | |
source /etc/X11/xinit/xinitrc.d/30-dbus | |
eval $(/usr/bin/gnome-keyring-daemon --start --components=gpg,pkcs11,secrets) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?hh | |
function f(?int $x): ?int { | |
if ($x === null) return $x; | |
else return $x * 2; | |
} | |
function x(): ?int { | |
return null; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Foo | |
{ | |
private $bar; | |
public function __construct(Bar $bar) | |
{ | |
$this->bar = $bar; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$xs = array(42); | |
foreach ($xs as $x) {} | |
var_dump(current($xs)); | |
$ys = array(42); | |
foreach ($ys as &$y) {} | |
var_dump(current($ys)); | |
$it = new ArrayIterator([42]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function _sqrt($n) { | |
$x = 1.0; | |
$y = 0.5 * (1.0 + 1.0/$n); | |
$z = 1e-10; | |
while (abs($x/$y - 1) > $z) { | |
$x = $y; | |
$y = (0.5 * ($y + $n/$y)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class App | |
{ | |
public $callables = []; | |
public function __construct() | |
{ | |
register_shutdown_function([$this, 'run']); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysum :: Num a => [a] -> a | |
mysum [] = 0 | |
mysum (x:xs) = x + mysum xs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once __DIR__ . '/vendor/autoload.php'; | |
$file = __DIR__ . '/testfile'; | |
$client= popen('tail -f ' . $file, 'w'); | |
stream_set_blocking($client, 0); | |
$loop = React\EventLoop\Factory::create(); |
NewerOlder