Seems to be missing the vital functionality of being able to evaluate snippets though, which is the biggest feature missing in Rust.
(defn people-in-scenes [scenes]
(->> scenes
(map :subject)
(interpose ", ")
(reduce str)))
You could evaluate the full function and then afterwards you evaluate `(people-in-scenes [{:subject "Test"}])`But, usually you want to evaluate just a piece, in this case we want to evaluate `(->> scenes ...)` but `scenes` is not in scope?
So we evaluate `(def scenes [{:subject "Test"}])` first and now we have scenes in scope wherever we are, with our test data, and we can select arbitrary snippets around the codebase that depend on `scenes` being in scope.
Repeat for all vars that are expected to be in scope, and you can jump around freely.
Sometimes I leave a statement that defines common data-structures to various names within a `comment` block so it's easy to jumpstart this interactive development when you're in a namespace.
There are other ways as well, but normally this is the easiest to get started with and does the trick for most cases.
>How exactly do you evaluate snippets in some environment even with REPL? I mean most code in a large system is part of a context that is required
This is a bad smell for me. You should always try to split your code in small pure functions that do one thing, it will help you with readability, with refactoring, with testing and depending on environment you could just replace the function with an different one at runtime.
The issue I hit though is with code that evolves over years, it starts simple and then each team member had to add some new feature and the simple functions get larger and alrger , the number of parameters increases etc , the solution is to take the time and re-analyze the updated problem and refactor or rewrite the solution to be again composed from simple parts that do one thing.
let me know If I misunderstand the thing you said about types, or you referring mainly about REPL
You would need the ability to keep your program running while inside a debugger while you were able to patch memory on the fly (not just replace instructions in a function body - which I reckon I could figure out with the help of that hot reloading in rust link I shared) but replace function signatures at debug-runtime and be able to serialise the image state to disk and arbitrarily resume it later... It just feels like square peg round hole.
Rust has a different development experience than lisp. It doesn't lend itself to stuff like structural editing (which is really fun to watch an experienced dev doing - Emacs lisp videos on yt are a good source for some mind bending productivity)
Although, the repository seems a bit... Weird. The README ends with:
> This is not an officially supported Google product. It's released by Google only because the (original) author happens to work there.
Why would Google release it if it's not their product/project? Why is it under github.com/google? Do Google own projects that people happen to work on in the free time just because you otherwise work at Google? Something smells fishy here, but wouldn't be the first time Google does fishy stuff.
* Have a "fairly flexible arrangement" to work on side projects when they want & potentially using Google hardware on work time but in exchange Google holds the copyright & it has to be published under the Google repo with the quoted disclaimer.
* Deal with a bunch more paperwork on per-project basis.
If people don't have a particularly strong attachment to their side-projects the first option is the "low hassle" option for flexibility to do side projects at work.
I would agree it is unfortunate developers don't push back harder against such a wanton "IP" grab by their employer--but hey, I guess that's what we get without collective representation or respecting our own value as developers.
This chap is up there with Eli Benderski’s blog for me, i really enjoy fasterthanlime’s long form articles.