Better HN
topnewbestaskshowjobs
Log inSign up

floppy-disk

4 karma · joined May 31, 2020 (6y ago) · 6 submissions

Submissions

comment 2y ago · link · parent

Whoa, interesting... What version are you running? Here's my system:

  $ ruby -v
  ruby 3.3.1 (2024-04-23 revision c56cd86388) [x86_64-linux]

  $ time ruby -e ''

  real 0m0.122s
  user 0m0.102s
  sys 0m0.020s
I found an old Reddit thread also hinting at bad start-up times: https://old.reddit.com/r/ruby/comments/aqxepw/rubys_startup_....

comment 2y ago · link · parent

While I write most of my scripts in Ruby and enjoy doing so, there is one gripe I have with it: its slow start-up time. On my machine, running an empty Ruby script takes about 100ms, compared to <10ms for Python, Perl, Lua, Bash.

One can mitigate the problem somewhat using the `--disable-gems` flag, but that's not a good general solution.

comment 4y ago · link · parent

Refactoring legacy code.

comment 6y ago · link · parent

There are also numerous people which promote the excessive use of small classes and methods like for example Kent Beck or Robert Martin. As always, there probably is no "right" answer, it really depends on context.

comment 6y ago · link · parent

> a lot of the developers I've observed are very bad at drawing coherent software boundaries

That's a very good point. Designing small components probably requires more effort and can also cause a lot of harm if done incorrectly.

comment 6y ago · link · parent

I would not agree that the bias towards OOP is a problem in the book, since most of the concepts are paradigm-agnostic. Nevertheless, I feel that the author exposes a rather opinionated (sometimes even dogmatic) and narrow view of software design.

Although I think that the book provides a lot of very valuable insights, I missed a more differentiated view of the concepts presented in the book. For example, in chapter 4 ("Modules should be deep") Ousterhout dismisses the use of small classes and methods. He argues that using many small classes and methods makes the system as a whole more complex because many little pieces have to be managed. I completely agree with that statement. But only under the assumption that software systems are static and never-changing. If we consider software systems as ever-changing, I would argue that using smaller pieces often provides the flexibility necessary for maintaining large systems.