BatmanAoD

joined 1 year ago
[–] [email protected] 15 points 9 hours ago (1 children)

... the issue I have is people lying and saying Rust is a drop in replacement for js

I am genuinely curious whether you've actually seen this claim before, or if you badly misunderstood or are simply exaggerating a claim about Rust being a good language for web servers, or if you simply made this up as a straw-man. I can't imagine anyone who knows what they're talking about using those words I that order.

[–] [email protected] 1 points 23 hours ago (1 children)

To be clear, you're saying you trust git metadata to be preserved even when forge/issue-tracking/etc metadata is not?

I suppose that's probably the case more often than not. I think it's still preferable to trust the forge you use than to spend any significant amount of time or effort trying to ensure that the team has strong enough commit-message discipline to compensate for the risk of losing data in an issue-tracker or forge.

[–] [email protected] 1 points 1 day ago (3 children)

"trust them" meaning trust github and gitlab?

[–] [email protected] 2 points 1 day ago (1 children)

My point is that "the comments aren't accurate" is also a people problem. And I absolutely disagree that commit messages are "documentation" of anything except the development history.

[–] [email protected] 2 points 1 day ago (5 children)

They are hard to discover… and hard to use.

Flippin' fantastic, that's exactly what I want out of my documentation tooling.

I absolutely agree it would be better if forge data were part of the repo itself rather than separate. But for teams that are using a forge in the standard way, they should rely on the forge for this sort of thing, rather than hide important information in an obscure git feature.

[–] [email protected] 5 points 1 day ago

But how does the alternative solutions compare with regards to maintainability?

Which alternative solutions are you thinking of, and have you tried them?

Rust has been mentioned several times in the thread already, but Go also prohibits "standard" OOP in the sense that structs don't have inheritance. So have you used either Rust or Go on a large project?

[–] [email protected] 0 points 1 day ago* (last edited 1 day ago) (4 children)

It's not documentation, though. That's my point. It's a byproduct of the development cycle, not a place to store important information.

Commit messages are tied to a commit, sure, but why do you expect developers to have better discipline in writing commit messages than they have in updating code comments?

[–] [email protected] 1 points 1 day ago (7 children)

I mean, I've been doing this for over a decade too. If teams are losing data from their issue tracker or source forge, that's a deep problem and not something that can be ameliorated by writing better commit messages.

[–] [email protected] 0 points 1 day ago (15 children)

The gitlog is intended for contributors of the project whereas the chamgelog is intended for users of the project.

That makes sense to me.

I think I would still argue, however, that for projects using github, gitlab, or any similar forge with a built-in pull-request + code-review feature, there's very limited value in spending time crafting good commit messages in a feature branch. All information that you may be tempted to put there would be more visible and more useful either as code comments (which applies to all projects, not just GH) or as comments in the PR description or discussion. (I also think it's often better to just squash feature branches on merge than to try to maintain a clean branch history while the feature is in development.)

I do think that the commit messages that actually end up on your trunk are important; but, with the exception of the final PR merge (or squash) commit, developers should minimize the time spent writing or thinking about these commit messages.

The one context in which I find details in historical commit messages potentially useful is when using git log -p to figure out when and why something changed. But even then, once I've found the relevant commit, looking up the PR to see if there was any discussion about the change in question is generally the next step; so again, having substantial detail in the commit message itself is unlikely to be helpful.

[–] [email protected] 3 points 1 day ago* (last edited 1 day ago) (18 children)

Why should I put manual effort into separately maintaining a changelog and a semantically meaningful commit history? If I'm going to manually maintain atomic commits with useful commit messages, why would I want the contents of those messages to be substantially different from the content of the relevant bullets of the changelog?

[–] [email protected] 4 points 3 days ago* (last edited 3 days ago)

The O'Reilly book Programming Rust is very much targeted at C++ users, even if it isn't explicitly marketed that way.

I read the first edition, which predated async Rust, so I can't comment on how the second edition handles that topic. But the handling of everything else was, I think, excellent.

[–] [email protected] 1 points 3 days ago* (last edited 1 day ago)

🤷 That wasn't my experience, and I used it as my primary dev environment for four years.

It doesn't go through a translation layer, though. WSL 2 has a whole separate kernel. You can even use GUI apps with Wayland.

34
submitted 9 months ago* (last edited 9 months ago) by [email protected] to c/[email protected]
 

Almost five years ago, Saoirse "boats" wrote "Notes on a smaller Rust", and a year after that, revisited the idea.

The basic idea is a language that is highly inspired by Rust but doesn't have the strict constraint of being a "systems" language in the vein of C and C++; in particular, it can have a nontrivial (or "thick") runtime and doesn't need to limit itself to "zero-cost" abstractions.

What languages are being designed that fit this description? I've seen a few scripting languages written in Rust on GitHub, but none of them have been very active. I also recently learned about Hylo, which does have some ideas that I think are promising, but it seems too syntactically alien to really be a "smaller Rust."

Edit to add: I think Graydon Hoare's post about language design choices he would have preferred for Rust also sheds some light on the kind of things a hypothetical "Rust-like but not Rust" language could do differently: https://graydon2.dreamwidth.org/307291.html

view more: next ›