Skip to content

Instantly share code, notes, and snippets.

Note to readers: This document is an early draft of a model for memory-safe references that I've been working on for the last ~2 years. While I think it is quite promising, the design is unfinished. The "regions" that I present in this document have not been given a formal semantics, and I have not explained where they originate from. My goal is merely to convince you that the design is promising, and that if seen to completion, it would advance the frontier of zero-cost memory safety.

Update March 2025: I am working on a newer version of this proposal, that aims to simplify the model substantially. When I have finished that proposal, I will put a link here.

Update August 2025: Verdagon has written an awesome blog post that explains this proposal at a high level. I recommend you check it out!

Abstract

In this document, I present a novel model for memory-safe references that aims to significantly improve upon the Rust-inspired model that Mojo c

@CoderPuppy
CoderPuppy / .cvimrc
Last active January 30, 2017 15:52
cVim RC
map j scrollLeft
map k scrollDown
map l scrollUp
map ; scrollRight
map K previousTab
map L nextTab
map J goBack
map I goForward
map C-k scrollPageDown
map C-l scrollPageUp
@CoderPuppy
CoderPuppy / vx-ace.rb
Created September 2, 2012 18:20
RPG Maker Plugin System
# VX Ace Plugin System by CoderPuppy
module Plugins
@all = []
def self.register(plugin)
@all << plugin
@all.uniq!
self
@CoderPuppy
CoderPuppy / approaches.rb
Created August 23, 2012 21:56
Instruction Set
# Vote which one is best
# No Data Registers, Current
set reg(0) => raw("Hello, ")
add 0, raw("Drew")
add reg(0), raw("!!!")
# Array of Data Registers
set "Hello, "
set "Drew"
function k() {
kill -9 $(ps ax | grep $1 | grep -v grep | awk '{print $1}')
}
@mattsears
mattsears / README.md
Created September 5, 2011 07:41
Gittr: A Git key/value store

Gittr.rb

Git as a key-value store! Build with Grit, it supports SET, GET, KEYS, and DELETE operations. In addition, we can also get the change history of key/values.

And since it's Git, we can easily enhance it to include other awesome Git features such as branches, diffs, reverting, and more!

Example:

@asaaki
asaaki / README
Created July 18, 2011 18:50 — forked from peterc/README
testrocket (origin by peterc)
TestRocket is a simple, tiny testing library for Ruby 1.9.
If => in a hash is a "hash rocket", then +-> and --> for tests should be
"test rockets"!
Simple syntax:
+-> { block that should succeed }
--> { block that should fail }