News for hackers. Stuff that matters.
Re:Cyclic dependencies are evil (2013) by squibbles on Saturday January 30, 2021 @12:12PM (#25970792)
I still cringe when I think back to some C projects from long ago, where the dependency chains of headers and libraries where unfathomably byzantine.

On a related note, lately I have been looking into some biochemistry topics and their relation to computer science. It seems that cyclic dependencies are possibly a requirement for life, which makes faithful simulations of biochemical processes an interesting challenge.

Re:Cyclic dependencies are evil (2013) by mattgreenrocks on Saturday January 30, 2021 @12:51PM (#25971174)
I’m a compiler nerd at the moment. I have an inherent trust of things that bootstrap themselves, as if it means they are conceptually more pure. I’m not sure whether that is 100% well founded, but it sounds similar to some of these observations. :)
Re:Cyclic dependencies are evil (2013) by ReactiveJelly on Saturday January 30, 2021 @01:02PM (#25971289)
I think self-hosting is just a little over-rated for languages. It's good that Rust and C++ are self-hosting, you'd expect those to be languages you can write a compiler in.

But Lua and JavaScript satisfy their own niche just fine without having popular runtimes written in themselves.

Re:Cyclic dependencies are evil (2013) by mattgreenrocks on Saturday January 30, 2021 @02:11PM (#25971978)
Most languages don't aspire to be so conceptually-complete that they insist on being bootstrapped. Which is fine, I make my living with them.

Those that do, however, are immensely beautiful and there is more to be learned from them.

Re:Cyclic dependencies are evil (2013) by TheBrokenRail on Saturday January 30, 2021 @02:10PM (#25971954)
There are a few JS interpreters written in JS, don't know about Lua.
Re:Cyclic dependencies are evil (2013) by jimmaswell on Saturday January 30, 2021 @12:58PM (#25971245)
The C language and gcc are a cyclic dependency too.
Re:Cyclic dependencies are evil (2013) by ReactiveJelly on Saturday January 30, 2021 @01:04PM (#25971308)
Only if you don't consider time, or optional dependencies. GCC 10 _can_ be built with GCC 10, but it was probably built with GCC 9 the first time around.

If you can bootstrap it, and you can, then it's not really a hard, unbreakable cycle, right? It's just an option that's quicker than starting from tcc or whatever every time.

Re:Cyclic dependencies are evil (2013) by nyberg on Saturday January 30, 2021 @01:16PM (#25971412)
But how would you build the first GCC in that chain?
Re:Cyclic dependencies are evil (2013) by pjmlp on Saturday January 30, 2021 @02:27PM (#25972109)
Using another C compiler, if none exists, create one in Assembly or other programming language in the target platform and go from there.
Re:Cyclic dependencies are evil (2013) by joshuaissac on Saturday January 30, 2021 @08:23PM (#25974803)
TCC 0.9.27 can build GCC 2.95.3. You can build TCC using GNU Mes, which itself can be built using M2-Planet, which is written in a subset of C.

https://www.gnu.org/software/mes/

Re:Cyclic dependencies are evil (2013) by fosslinux on Saturday January 30, 2021 @11:20PM (#25975895)
Furthermore, M2-Planet can be built by another C compiler written in assembly, all the way down to hex instructions.

https://github.com/oriansj/mescc-tools-seed/

Re:Cyclic dependencies are evil (2013) by pabs3 on Saturday January 30, 2021 @11:59PM (#25976132)
These projects are from the Bootstrappable Builds folks:

https://bootstrappable.org/ https://bootstrapping.miraheze.org/wiki/

Re:Cyclic dependencies are evil (2013) by dilawar on Saturday January 30, 2021 @12:18PM (#25970848)
That is an interesting observation. I wonder whether the cycling in chemistry is more about information flow then like (negative?) feedback, it helps in making a stable system.