TIL cargo is exploring a Rust script mode, essentially a concatenation of Cargo.toml and main.rs
miniblog.
I've been using a 'golden tests' library for testing my parser, and it's just delightful. Rather than writing a verbose assertion about the resulting AST, I can just re-run my tests until the output looks good!
I've been using a 'golden tests' library for testing my parser, and it's just delightful. Rather than writing a verbose assertion about the resulting AST, I can just re-run my tests until the output looks good!
I'm using https://github.com/jfecher/golden-tests currently, which can automatically update the output in the file.
Example commit:
The Ruby on Rails guides use "please" when suggesting other resource to read or best practices to follow. For example: https://guides.rubyonrails.org/autoloading_and_reloading_constants.html
I've not seen this docs convention before. I certainly see the appeal for describing best practices: "your collaborators will appreciate it!"
Are there any good tools for generating boilerplate code?
If I'm a web framework author, I'd love to provide a *discoverable* tool for defining a new controller. This is especially important if files need specific naming conventions or to be in certain directories.
Are there any good tools for generating boilerplate code?
If I'm a web framework author, I'd love to provide a *discoverable* tool for defining a new controller. This is especially important if files need specific naming conventions or to be in certain directories.
I've seen tools like yeoman and create-react-app, but they seem to focus on new projects. There's also no VS Code integration that I'm aware of.
I'm still experimenting with patch display in difftastic.
The change to the imports are clearer in the patch mode, but the side-by-side mode does make the if/else changes more readable.
Patches are probably worthwhile anyway due to their machine readability.
I'm experimenting with a patch-style display format for difftastic.
What do you think? Do the colours work? What about the last example, where there's only whitespace changes and the syntactic diff has nothing to highlight?
Do you think values and types should be in separate namespaces? Why/why not?
Difftastic 0.55 is out! In this release:
* Support for VHDL and Objective-C
* Improved support for XML
* The usual smattering of bugfixes :)
Do any package managers use bittorrent? I associate bittorrent with distributing large files, but it seems like it would really help scaling.
Most traffic to package managers is from CI systems, which could instead run their own local seeding nodes.
@skybert@emacs.ch Difftastic has very little unsafe, just the FFI to tree-sitter libraries.
That said, I've actually seen safe Rust segfault in the past!
Difftastic is written in Rust, so I was surprised to get a user report of a segfault.
After some investigation, it turns out that it's a segfault in git itself, which has existed since 2014! https://lore.kernel.org/git/CAFXAjY7XcL1APhLRXU8TO96z=f7957f2ieK56dHVsXUay55vpg@mail.gmail.com/T/#u
(Upstream has already kindly written a patch.)
Writing a good REPL is hard. Despite Ruby's age, they're still finding opportunities to improve the UI!
I'm a big fan of segmented stacks (or 'split stacks'), where stack frames are heap allocated, You can write recursive functions with less worry, and you get better tracebacks than TCO.
Go is the most popular language with this feature, to my knowledge: https://dave.cheney.net/2013/06/02/why-is-a-goroutines-stack-infinite
I'd assumed that LLVM didn't support this, but gollvm handles it fine! https://groups.google.com/g/golang-nuts/c/ivOZ-j6Zt2c/m/BUBX2Td9BgAJ
Showing 121-135 of 144 posts





