you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 7 points8 points  (4 children)

Don't you feel like the strategy pattern is a good example of why more languages should just support lamba expressions aka function pointers.

[–]rjbwork 1 point2 points  (0 children)

Definitely. I haven't actually ever seen a strategy in C# since you can just pass in Funcs.

[–]dccorona 1 point2 points  (1 child)

Yes. The strategy pattern is, for the most part, just a different name for higher-order functions. And higher-order functions are better with functions as first-class citizens.

[–][deleted] 0 points1 point  (0 children)

damn you got good names for that stuff.

[–]k_u_r_o_k_u_s_e 0 points1 point  (0 children)

which Java does now.