Hey folks! I've been writing some Rust lately and published a few small crates over the last couple of weeks. They aren't anything super advanced, but I'd really love to get some eyes on my code to see if I'm doing things the "Rusty" way.
Here are the repos:
claris - A clean, minimal, and fluent logging framework.
LGTM. No obvious anti-patterns/unidiomatic use cases, as far as I can tell.
Out of sheer curiosity, did you build all of these from the ground up on your own? Or was there any LLM-gen involved, at one point or the other? Something about this:
A clean, minimal, zero-dependency by default fluent logging framework. Features include module-level filtering, ANSI terminal colors, and perfect output alignment.
just seems off to me, for some reason. As do the comments like:
I wouldn't even know what character that is, much less be able to type it, in the spur of the moment. To have it perfectly aligned throughout the whole module? I commend your perfectionism efforts.
I am out of luck because implemented all your tools a year ahead. I need to slow down and relax, you will implement everything I need in the future. Just kidding. Good work, man.
If you really want to, it can be automated - I have this in my nvim/init.lua config:
vim.api.nvim_create_user_command("Div", function(opts)
local text = "// -- " .. opts.args .. " "
local fill = string.rep("-", math.max(0, 77 - #text))
vim.api.nvim_put({ text .. fill }, "l", true, true)
end, { nargs = 1 })
When I type :Div u64 / i64 it generates just such a line. Although I used '-', not "em dash", which seems to be one of the LLM tell tale signs. On par with decorating a README.md with colourful emoticons.
Note that this isn't an em-dash (β, U+2014); this is a horizontal box-drawing character (β, U+2500). I'm not sure how much LLMs like to use box-drawing characters for things like this.
You are right - you know your dashes - there are quite a few - they look similar, but there are small differences; In a terminal EmDash doesn't go all the way through a cell. Like it does here (browser).
Ascii Minus U+002D -----------------
Unicode Minus U+2212 βββββββββββββββββ
EnDash U+2013 βββββββββββββββββ
EmDash U+2014 βββββββββββββββββ
Box U+2500 βββββββββββββββββ
Huh. Definitely wouldn't be able to tell it was these little guys all along. DDG just failed to look it up altogether. Never used any in my own code either. Though I can see the aesthetic appeal, I suppose. Quite trivial to script/automate, as well. My LLM paranoia might be getting the best of me, lately.
To the OP - in the spirit of an attempt to stick to the actual topic at hand: I'm pretty sure half of the replies in this thread discussing box drawings and em-dash'es instead of your code does imply that none of the responders were able to find anything of note to review, nitpick or give any worthwhile feedback about. Good job, so far. Keep up the good work.