And here I was happy to learn something new on social media contradicting my previous knowledge lol. But yeah, I definitely intend on having a basic chemistry refresher video now!
And here I was happy to learn something new on social media contradicting my previous knowledge lol. But yeah, I definitely intend on having a basic chemistry refresher video now!
That is very interesting, and not something I remember from my very limited exposure to chemistry in school. Thanks for clearing that up!
Yeah, and if you saturate hot tea, won’'t the sugar simply materialize back as the tea gets colder? Seems to me that nothing about this has to do with saturation.
What you seem to be describing is one big class with lots of responsabilities, and not circular dependency. Personally, I don’t think it is ideal, and I don’t know about your specific case so I could be wrong, but I have never seen a legit case for bloated classes. That being said, making a big class is still much better than splitting it into inter-dependant classes. Classes that know each other are so cohesive that they might as well be the same class anyway.
To add onto the circular dependency problem, it is not just about readability and cognitive load (though there is some of that), but cyclic dependencies actively break things, and make it much harder to manage the lifecycle of a program. No dependency injection, poor memory management, long compile times. It is a huge hack, and I understand that you think it can be the proper solution sometime, but it is really just a bad thing to do, and it will bite you some day. And I am assuming here that you’re using a language that is friendly, in some languages you won’t even compile past a certain point, and good luck cleaning up that mess.
It does not get more complicated to split your example. What gets more complicated is giving all sort of unrelated responsabilities to a single class, simply because it is the path of least resistance.
In your example, all you need is an extra module listening for configuration changes and reacting to it. This way you leave your context-specific logic out of your data model, no need for cyclic dependency. There are so many downsides to cyclic dependency, to justify it because splitting your logic is “too complicated” really isn’t a strong argument.
A crepe is like 100 calories and you can pour like 5 in less than 10 minutes. But anyway, to reach their own. personally I hate chopping stuff even if it takes 1 minute.