Let's Be Real About Dependencies: https://wiki.alopex.li/LetsBeRealAboutDependencies
Contrasting C/C++ dependencies with languages with first-class packages (Rust, Go, JS) and finding similar level of dependencies! Perhaps modern package managers just make this more obvious.
miniblog.
After thoroughly confusing myself for a minute, I've added a feature to difftastic to warn you if both arguments are the same.
With hindsight, I should have done this much earlier.
Sometimes I suspect you could send a pull request to any project replacing `foo` with `foo + 1` anywhere by saying "fix off-by-one error". `foo + 1` rarely looks wrong.
Rust's Iterator interface is growing on me. I replaced a bunch of `i += 1; foo.get(i)` loops with explicit calls to `.next()`. It's less code and easier to reason about.
A delightful suggestion from the Rust compiler: you have no field of that name, looks like you need to access it via another field!
Adding a snazzy compiler error is a rarely used feature (in each individual case), but it's wonderful when you hit that case.
I'm beginning to think this last sentence was a mistake. Lots of software fixes crashes in new versions.
Perhaps I should have a "N releases since last fix for a crash" count?
Difftastic 0.23 is out! I've been tuning diffing and display and I think the results look fantastic.
* Parent delimiters are modelled accurately
* Display uses blank lines as an alignment hint
* Textual diffing is way faster too!
Anecdotally, I've noticed more frequent doc comments in languages that put them inside the function (e.g. Python, Lisp) rather than outside (JS, Rust).
Perhaps it's easier to write the rough signature before the explanation?
I've finally fixed an issue where difftastic wasn't showing optimal diffs if you wrapped an expression in another expression.
For example, lisp expression changes are super readable now :)
It's weird how ! denotes side effects when it's allowed in names (Scheme, Ruby) but there isn't a clear equivalent in other languages.
My only theory is that "side effects" is often vague. list-add!, table-drop! and ping! are very different effects.
An overlooked PL question: what is easy to try in a given language? In lisp it's easy to try adding extra syntax. In Rust it's easy to try parallelism on iterators (rayon).
Are there other examples? Perhaps Perl and regexes or Haskell and STM?
I've found an interesting case where difftastic and GitHub diff results are pretty different.
I've replaced some function calls with a DiffResult and the matching is a bit aggressive, but showing `diff_directories` changes is really nice.
(Commit shown: https://github.com/Wilfred/difftastic/commit/4883edd90cc8011041a6cee0622805d6bc7847a0)
Writing an IRC server, exploring object systems, and enabling hot reloading for clients: https://technomancy.us/197 (in Lua and Fennel)
Contrasting the C++ committee with Rust's RFC process, and avoiding antagonistic design evaluation: https://www.reddit.com/r/cpp/comments/td5np8/to_save_c_we_must_save_abi/i0hsxod/
There's something of a tradition of REPLs having personalities in lisp. I've seen Common Lisp tools (e.g. slime/sly) and Clojure (e.g. cider) say encouraging things, but Fennel is almost judgemental :)
Sometimes a good bug report is just nerd sniping.
I'm finally reaching a point with difftastic where I'm pretty happy with performance. 0.22 has some effective heuristics for making the tree diff faster, and 0.23 will have Myers' diff algorithm for text.
I've released difftastic 0.22!
* Added PHP, and improved C++ and Rust
* Files are split on clearly unchanged regions before diffing, hugely improving performance
* A ton of improvements to nested diff heuristics
Flamegraphs are an indispensable tool, but sometimes I overuse them. Here's an example for difftastic -- it spends most of the time computing the shortest path.
I was able to make the diff graph smaller, making difftastic much faster -- but the new flamegraph looked the same!
Showing 761-780 of 7,506 posts