Recent snippets

Popular snippets

  • Implementing active objects with a MailboxProcessor

    Mailbox processors can easily be used to implement active objects. This example shows how to do that with a reusable wrapper type and minimal boilerplate code in the actual class definitions. Supports both asynchronous calls and synchronous calls. For the latter case, exceptions are automatically propagated back to the caller.

    90 people like this

    Posted: 6 years ago by Wolfgang Meyer

  • Split a list

    Three ways to split a list in half (but not necessarily in the middle). A forth version added that's very short and should be fast, as we only use List.fold. New champ found.

    75 people like this

    Posted: 6 years ago by Dmitri Pavlenkov

  • WPF / SilverLight Converter II

    version 1 is This new version support convert from any existing function to a converter function by using composition and pipeline. The convert function is to make the function signature agree to the IValueConverter interface. You can add new functions in the FunctionLibrary module and reuse the class definition to reduce the coding effort. The first sample is to show how to make the converter pipeline work, the second one is a debugger converter used to debug the data binding problem.

    83 people like this

    Posted: 6 years ago by Tao Liu

Snippets by tags

sequence (29) tryfsharp (48) async (92) parsing (22) computation builder (14) http (14) fold (19) seq (49) string (18) learning f# (16) lazy (18) pattern matching (12) math (32) array (18) agent (20) kata (17) recursion (26) collections (16) lists (13) web (23)

View all...

Database contains 2150 snippets out of which 1482 is public.