Skip to content

Instantly share code, notes, and snippets.

<!DOCTYPE html>
<html>
<script src="p5.js"></script>
<script>
function setup() {
createCanvas(800, 600);
background(255);
}
function draw() {
import processing.pdf.*;
int gridW = 5;
int gridH = 5;
int cellW = 30;
int cellH = 30;
int nodeR = 10;
@wxs
wxs / gist:d773cb2a2e9891dbfd63
Last active March 13, 2020 11:50
Legal characters in Swift 1.2 Operators
Have you always wanted to define the sailboat operator in Swift? Well now you can!
3 ⛵4 == "sailboat"
Swift 1.2 significantly increased the number of legal characters in custom operators.
I've generated a list for ease of copy/paste below.
Generated from reference here: http://apple.co/1EEXHDQ
The characters

Keybase proof

I hereby claim:

  • I am wxs on github.
  • I am wxswxs (https://keybase.io/wxswxs) on keybase.
  • I have a public key whose fingerprint is 5FB5 F48E A4CD 9905 903C 620F 7515 7DB5 7850 112D

To claim this, I am signing this object: