Reputation
8,182
Top tag
Next privilege 10,000 Rep.
Access moderator tools
Badges
1 21 38
Newest
 Guru
Impact
~291k people reached

Feb
5
comment What are the drawbacks to mapping integral identifiers to enums?
i'd say you almost certainly so not want to wrap each int in a class but in a struct
Feb
3
comment Why is using an optional preferential to null-checking the variable?
you almost never want to use isPresent, you should usually be using ifPresent or map
Jan
8
awarded  Guru
Dec
17
awarded  Yearling
Dec
16
comment Workaround for implementing operations on doubly linked or circular data structures in languages with immutable data
depending on what is needed a zipper might also be useful
Dec
15
comment Does a C# event have to have an object type as its first parameter?
+1 for monkeys natch ;)
Dec
10
comment Comparison Function Returns True or False
alternatively this is called something different in other languages e.g. java 8 would call this a BiPredicate
Nov
24
comment What is the purpose of wrapped values in Haskell?
on the Java side, as I said Optional in a monad but as a pattern only, Java lacks the power in its type system to write a function that can operate on any monad
Nov
24
comment What is the purpose of wrapped values in Haskell?
at the very least i'd think the static/dynamic divide is a difference between them, but I don't know enough python to know if there are any other implications
Nov
24
answered What is the purpose of wrapped values in Haskell?
Nov
18
comment Should we test all our methods?
It will depend on your system to some extent, if you are developing a system with a moderate to hight level of safety certification you will need to cover all methods regardless of triviallity
Nov
6
comment Function behavior dependent on the calling class
Could you not have a callback from N to the B children?
Oct
29
comment UML: Should an asynchronous request-response message exchange be modelled as two ports/interfaces or one
I don't think this changes the edvice though, unless you are trying to produce an executable model then it only depends on what you want the diagram to show. Consider why are you producing this diagram in the first place? who is it for? what inormation do they want from it?
Oct
28
comment Should actions / methods be conjugated in comments?
the example comments here are nearly useless compare to docs.oracle.com/javase/8/docs/api/java/util/stream/…
Oct
19
comment How to write maintainable, not brittle, unit tests for a GUI?
I think this is part of the problem though, fundamentally you can't really test any interface by unit testing alone as their raison d'etre is to interface to something. GUIs are no different in this respect.
Oct
15
comment Functional programming: Compare all items in an array
ecmascript for and appears to be every
Oct
8
comment Does C# 6.0's new null-conditional operator go against the Law of Demeter?
anything more than that does not necessarily break LoD e.g. builder pattern
Sep
29
comment What is a good name for functions like 'sum', 'max', 'min'?
aggregate aka fold aka catamorphism aka reduction
Sep
9
comment How is dependency inversion related to higher-order functions?
Many functional languages also allow you to create a type that encapsulates a function as well
Sep
6
comment What's the use of .Any() in a C# List<>?
@SargeBorsch any is the same in haskell?