First draft of typing spec