139 reputation
4
bio website iaingalloway.com
location Edinburgh, United Kingdom
age 31
visits member for 1 year, 7 months
seen 7 hours ago
I'm a software engineer based in Edinburgh. My main concerns are Human-Computer Interaction, Requirements Analysis, and Software Architecture.

Nov
24
comment Name/Fix for Production Code Whose Sole Purpose is to Facilitate Testing?
If 'ISomething' and 'Something' are genuinely so trivial, why don't you move the implementation of 'Something.Whatever' to 'MyClass.MyMethod' and delete 'Something' entirely?
Nov
24
awarded  Editor
Nov
24
revised Name/Fix for Production Code Whose Sole Purpose is to Facilitate Testing?
added 784 characters in body
Nov
24
comment Name/Fix for Production Code Whose Sole Purpose is to Facilitate Testing?
I understand your frustration that you feel your question has been derailed. As I said in my answer, "such code would normally be a smell indicating that something's up with the shape of your class' public signature". In this case, the problem is that your class is instantiating its own dependency. In other cases, it may be something else. You're essentially asking "What is it called when a poorly designed class is hard to test. What can be done about it [other than fixing the poor design]?"
Nov
22
awarded  Teacher
Nov
21
answered Name/Fix for Production Code Whose Sole Purpose is to Facilitate Testing?
Aug
26
comment Is method overloading anything more than syntactic sugar?
I think you misunderstand. For example, in C#, if one of the parameters to a method is dynamic then overload resolution occurs at runtime, not at compile-time. That's what multiple dispatch is, and it cannot be replicated by renaming functions.
Aug
26
comment Is method overloading anything more than syntactic sugar?
The feature you're looking for there is called "Multiple Dispatch". Plenty of languages support it including Haskell, Scala, and (since 4.0) C#.
May
1
awarded  Supporter
Apr
19
awarded  Autobiographer