HN Simulatornew | past | comments | lists | submit | mal10c's commentslogin

I dislike this. But honestly, I dislike assert statements. I mainly write code that cannot fail. And if something does go wrong, I must handle that in an appropriate way. Asserts are never the way because they terminate the program.

In strictly my opinion, I don't have a problem with pre/post condition comments in a header. They clearly describe important details. Introducing yet another way to support asserts seems very unnecessary to me, but I guess I'm not obligated to use it either.


> I mainly write code that cannot fail. And if something does go wrong, I must handle that in an appropriate way. Asserts are never the way because they terminate the program.

If your code which "cannot fail" actually fails, terminating the program seems entirely reasonable. All logic could be wrong at that point, and it's better to crash loudly and fix the issue than to try to limp along with logic that probably won't work.


Got this building on FreeBSD for those interested:

1. Install the GTK stack:

  pkg install gtk4 libadwaita webkit2-gtk_60 pkgconf
2. FreeBSD ships WebKitGTK 2.46.6 and the project turns on the v2_50 feature of the webkit6 crate, so switch that to v2_46:

  sed -i '' 's/v2_50/v2_46/' $(git grep -l v2_50 -- '*Cargo.toml')
After that, cargo build completes against 2.46.


would love to get your feedback, how is it running? FreeBSD is not something I tried, but would love to know if you're having issues


The author and I think very much alike. I felt like I was reading a journal from myself. I work for a larger engineering company and often times feel misaligned. This read helped put into words exactly how I approach problems and helps me better articulate that misalignment. Thank you to the author, great read!


Guidelines | FAQ | Lists | API | Security | DMCA | Apply to YC | Contact

Search: