Skip to main content
14 events
when toggle format what by license comment
Feb 9, 2016 at 6:06 history edited 200_success CC BY-SA 3.0
deleted 701 characters in body; edited title
Aug 27, 2012 at 23:13 vote accept Arne
Aug 27, 2012 at 15:48 answer added Winston Ewert timeline score: 1
Aug 27, 2012 at 13:15 history edited Arne CC BY-SA 3.0
added 5375 characters in body
Aug 27, 2012 at 6:35 comment added Arne @Joan Charmant I do agree with you, but there's some kinds of problems where it's not that easy. For me, there's a threshold for how long a class and a method may get before I am willing to split them. And there's another one for when I'm willing to split a method into sub methods: Each one has to be easily understood and has to do something a human deems sensible. So a matrix multiply is fine, but when will I need some of LU factorization stuff with the relevant state information in another context? And how should I name that?
Aug 27, 2012 at 6:29 comment added Arne @Corbin: I watched the video, thanks. I kind of disagree with the presenter, though. Not in principle - but I prefer simple type systems and fewer code I have to read and understand to simple methods - as long as I can still understand what the method does and it's well named and documented. I also think abstract classes are a (strong) code smell and I vastly prefer interfaces and flat type hierarchies.
Aug 26, 2012 at 19:43 comment added Joan Charmant « The // do stuff part uses too many variables to extract it into a method. » is the first code smell. Try to refactor it in several independant methods, or group the parameters into a dedicated class. After that you can have e1 and e2 each in its own method, and decide to call one, the other, or both.
Aug 26, 2012 at 6:00 history tweeted twitter.com/#!/StackCodeReview/status/239603318710759425
Aug 25, 2012 at 17:57 comment added Corbin Should be a good starting point if you decide to go the route dreza stated (which I believe is the correct route): youtube.com/watch?v=4F72VULWFvc
Aug 25, 2012 at 17:53 comment added Arne Intended and possible. Yes
Aug 25, 2012 at 13:21 comment added Denis Tulskiy is it possible that only code for e2 should be executed?
Aug 24, 2012 at 19:42 comment added dreza Without really seeing more of the code a common suggestion is to use inheritance and polymorphism. A first step would be to more common code to code to methods then once that is done decide if a seperate class will encapsulate the functionality you are seeing and the variables used.
Aug 24, 2012 at 17:54 history edited Arne CC BY-SA 3.0
edited title
Aug 24, 2012 at 17:47 history asked Arne CC BY-SA 3.0