Skip to content

Instantly share code, notes, and snippets.

Jason Orendorff jorendorff

  • Nashville, TN
Block or report user

Report or block jorendorff

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View bad.txt
$ hg log -r tip
changeset: 539025:519828d4a0a5
tag: tip
parent: 538768:93075ec49df3
user: Jason Orendorff <jorendorff@mozilla.com>
date: Tue Apr 09 13:11:27 2019 -0500
summary: Bug 1539821 - Part 1: Delete ModifierException::NoneIsOperand. r?jwalden
================================================================================ 2019-04-09 13:11:34
View pratt.dfy
// *** Basics *****************************************************************
// A nonzero number's divisors are the numbers that divide it evenly.
//
// Also called "factors". The divisors of 12 are 1, 2, 3, 4, 6, and 12.
function divisors(k: nat): set<nat>
requires k > 0
{
set n: int | 0 < n <= k && k % n == 0
}
View t90.js
try {
var P60 = 2;
while (P60 !== 1) {
switch (P60) {
case 2:
(function t90() {
var X60 = 2;
while (X60 !== 5) {
switch (X60) {
case 2:
View decorators-v3-feedback.md

Feedback on static ("v3") decorators

Please thank littledan and the other champions for (in short) doing everything right.

I'm convinced static ("v3") decorators are not the way forward.

I think the concrete disadvantages of a static design should be taken more into account:

View log.md

Here's one of the ORIGINALRANGE changesets:

$ hg log --graph --hidden -r 0262c62d81e5
x  changeset:   528466:0262c62d81e5
~  parent:      528452:47e514e01c5c
   user:        Jason Orendorff <jorendorff@mozilla.com>
   date:        Thu Feb 21 09:51:45 2019 -0600
   obsolete:    rewritten using prune as 528566:e7fd0ec90ddf
   obsolete:    rewritten using pick as 528814:b3cce8cc8cf8
View any_string.py
import random
class IndexedList:
""" Like a list, but append-only, values must be hashable, and duplicates are ignored. """
def __init__(self, values=None):
self._list = []
self._index = {}
if values is not None:
for v in values:
View gist:06363f3c08b9157b09030a3fc93440f1

ICYMI: New JavaScript Language Features

Let's talk about JavaScript.

Here are five new language features that are available in Firefox Nightly. These are new things that weren't there the last time we did this.

I'm going to move quickly, because although the things are small, there are several of them.

View woe.console
================================================================================ 2018-11-29 09:36:47
~/work/gecko$ hg diff
================================================================================ 2018-11-29 09:36:48
~/work/gecko$ hg up -r central
13 files updated, 0 files merged, 0 files removed, 0 files unresolved
================================================================================ 2018-11-29 09:36:55
~/work/gecko$ mach bootstrap
View littlepig.js
var total = 0;
var points = 0; // points so far in the current round
var draw = 0; // how many cubes you've drawn so far in the current round
var round = 1;
while (round < 20000) {
print("round", round);
points = 0;
View stream-vtables.patch
changeset: 511721:b9b50b3dec73
tag: tip
parent: 511719:8584c117d229
user: Jason Orendorff <jorendorff@mozilla.com>
date: Mon Nov 12 18:08:38 2018 -0600
files: js/public/Stream.h js/src/builtin/Stream.cpp js/src/builtin/Stream.h js/src/jsapi-tests/testReadableStream.cpp js/src/vm/Runtime.cpp js/src/vm/Runtime.h
description:
No bug yet - Abstract base class for external underlying sources. r?baku,jwalden
You can’t perform that action at this time.