interface terminal-input { /// The input side of a terminal. resource terminal-input; // In the future, this may include functions for disabling echoing, // disabling input buffering so that keyboard events are sent through // immediately, querying supported features, and so on. } interface terminal-output { /// The output side of a terminal. resource terminal-output; // In the future, this may include functions for querying the terminal // size, being notified of terminal size changes, querying supported // features, and so on. } /// An interface providing an optional `terminal-input` for stdin as a /// link-time authority. interface terminal-stdin { use terminal-input.{terminal-input}; /// If stdin is connected to a terminal, return a `terminal-input` handle /// allowing further interaction with it. get-terminal-stdin: func() -> option; } /// An interface providing an optional `terminal-output` for stdout as a /// link-time authority. interface terminal-stdout { use terminal-output.{terminal-output}; /// If stdout is connected to a terminal, return a `terminal-output` handle /// allowing further interaction with it. get-terminal-stdout: func() -> option; } /// An interface providing an optional `terminal-output` for stderr as a /// link-time authority. interface terminal-stderr { use terminal-output.{terminal-output}; /// If stderr is connected to a terminal, return a `terminal-output` handle /// allowing further interaction with it. get-terminal-stderr: func() -> option; }