3 ms·
Note that with strong typing this is less of an issue -- with Rust you can just go to http://docs.rs/<nameofcrate> http://docs.rs/<nameofcrate> and navigate the
by Manishearth 9y ago
Note that with strong typing this is less of an issue -- with Rust you can just go to http://docs.rs/<nameofcrate> http://docs.rs/<nameofcrate> and navigate the structured docs. They may lack explanatory text, but you can click around them and search and it's overall much nicer than fiddling around in a REPL.
(Still, doesn't fit all use cases of a REPL for this. REPLs are especially nice for when you want to fit together highly generic APIs)
- derefr 9y agoTrue; but also, "strong typing" on its own isn't a panacea for guidance; unless you're writing Coq or Agda, the API functions you're calling are still going to have preconditions that are not encoded in the type signature, so you're still (partially) reliant on having either good docs or a REPL [or clumsy REPL-equivalent, like exploratory unit tests] to inform you of those preconditions. And if you are writing Coq or Agda—well, you certainly don't need a REPL at that point. The code writes itself. ;)
- Manishearth 9y agoYeah, like I said, doesn't fit all use cases, but it does fit the primary one.
- curun1r 9y agoAlso, cargo doc --open for offline version of docs.rs :-)