Input Hooks

Input hooks are a special form of hook that is called whenever input is available on a particular port. They are treated differently than normal hooks - use add-input-hook! and remove-input-hook! to manipulate them. Like regular hooks and unlike timer hooks, input hooks are not one-shot - they trigger every time input is made available on the particular port, and do not go away until explicitly removed. An input hook may safely remove itself from within its own invocation.