An example of the instrumentation performed by wasm-trace.
See the diff between the two versions of function_calls.wat
.
#[no_mangle] | |
pub extern "C" fn double_subtract5_add1(x: i32) -> i32 { | |
let result = double(x) + negate(5) + 1; | |
return result; | |
} | |
#[no_mangle] | |
pub fn double(x: i32) -> i32 { | |
return x * 2; | |
} |
Hidden dependencies
Sarah Lim, Northwestern University
Update, September 2019: This Gist detailed an early idea which formed the basis for a major research project. For more information, you can read the resulting full paper, which received Best Paper Honorable Mention at UIST 2018. A tool based on this research is now available on Firefox Nightly.
What are hidden dependencies?
Hidden dependencies between CSS properties are a common source of beginner confusion. For instance, a user might write the following code in order to vertically align some text within a <div>
:
var config = { | |
templateSheetName: 'TEMPLATE', | |
dateFormat: 'ddd M/d', | |
sheetTitlePrefix: 'Week ', | |
daysPerSheet: 7, | |
showLatestOnLeft: true, | |
dateHeaderRow: 1, | |
}; | |
// Get the first sheet from the given spreadsheet. |
\documentclass[$if(fontsize)$$fontsize$,$endif$$if(lang)$$babel-lang$,$endif$$if(papersize)$$papersize$paper,$endif$$for(classoption)$$classoption$$sep$,$endfor$]{$documentclass$} | |
$if(beamerarticle)$ | |
\usepackage{beamerarticle} % needs to be loaded first | |
$endif$ | |
$if(fontfamily)$ | |
\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$} | |
$else$ | |
\usepackage{lmodern} | |
$endif$ | |
$if(linestretch)$ |
Argument | Example | Notes |
---|---|---|
cmd |
['python', '-m', '$project'] |
Required if shell_cmd is empty; overridden by shell_cmd ; searched in PATH |
shell_cmd |
yarn build |
Required if cmd is empty; overrides cmd |
working_dir |
?? | Temporarily change to directory before executing cmd |
env |
{ EDITOR: 'vim' } ? |
Can merge in a dictionary before passing to cmd ; expands environment variables. |
shell |
true |
Runs cmd through the shell if true ; noop if shell_cmd is used |
path |
/User/sarah/git |
Used by cmd ; expands environment variables. |
This README provides general instructions for installing Node.js and npm ecosystem projects from GitHub.
Many project READMEs assume a baseline level of user knowledge, but the following "Getting Started" section isn't very helpful to an absolute beginner:
npm install
Sarah Lim (http://sarahlim.com/eecs-111)
In most countries, the age of majority is 18. Some countries have different laws. In Scotland, for instance, the age of majority is 16.
Suppose we want to write a program to determine whether someone is a legal adult. We'll write a global version that works for most countries, and a Scotland-specific version.