Add extension to System.Type that returns the name of type including generic arguments in a nice readable format. It returns only short names of generic type and type arguments.
21 people like thisPosted: 14 years ago by Tomas Petricek
Example follows this, translated to FSharp: https://msdn.microsoft.com/en-us/library/dn903708.aspx Just instead of copy&pasting C#, add a new F# class library and paste this code to there, then add that to reference to your C#-project.
3 people like thisPosted: 7 years ago by Tuomas Hietanen
This snippet is helpfull in the following cases: 1) After a consolidation operation using the fold function we need to know how many elements have been processed. 2) A consolidation operation needs to use the index of each of the elements processed and we don't want to use the mapi function first. 3) A combination of the above. Since the following snippet just adds a wrapper to the existing Fold function we can repeat the approach for arrays and sequences (including the plinq ones)
31 people like thisPosted: 13 years ago by Horacio Nuñez
Normally, you'd add two numbers with the '+' operator. But why do that when you can use Type Extensions, custom operations on Computation Expressions, customer operators, and more?
11 people like thisPosted: 6 years ago by Phillip Carter