TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

ed(1) in Rust

5 pointsby beefhashover 4 years ago

1 comment

ekiddover 4 years ago
This repo is just an obvious and trivial joke about ed, which notoriously uses &quot;?&quot; for all error messages:<p><pre><code> let mut x = String::new(); loop { io::stdin().read_line(&amp;mut x) .expect(&quot;?&quot;); println!(&quot;?&quot;); } </code></pre> It would actually be fun to implement ed in Rust—it&#x27;s the best of of the popular low-bandwidth &quot;line editors&quot;, with some nice support for regex-based search and replace. It&#x27;s one of the few editors that could be a used with a slow line-by-line printer as the only output device.