discriminated-union
How can I transform a large discriminated union tree to a readable form?
The following type is clearly quite large so manually writing the code to convert this to a readable form would be tedious. I would like to know the simplest way to display the tree in a readable form[详细]
2023-01-18 04:07 分类:问答Discriminated unions and inheritance
I\'m looking to create a scene-graph for my F# project somthing like: root ->player_bob -->torch ->enemy_1[详细]
2023-01-14 02:27 分类:问答Scrap Your Boilerplate in f#
I\'ve used the Scrap Your Boilerplate and Uniplate libraries in the Haskell programming language, and I would find that form of generic programming over discriminated unions to be really useful.Is the[详细]
2023-01-13 08:19 分类:问答Can discriminated unions refer to each other?
I\'m building an expression tree using discriminated uni开发者_如何学编程ons. The below code:[详细]
2023-01-08 15:13 分类:问答Shared cases in F# discriminated unions
I want to write something like this: type NumExp = Num of float type Exp = Num of float Dot of NumExp * NumExp[详细]
2023-01-05 20:19 分类:问答Discriminated union in C#
[Note: This question had the original title "C (ish) style union in C#" but as Jeff\'s comment informed me, apparently this structure is called a \'discriminated union\'][详细]
2023-01-05 11:31 分类:问答Haskell's "deriving Show" in F#?
In Haskell it is easy to make a开发者_运维百科n algebraic type/discriminated union \"displayable\" as a string by simply adding deriving Show to the type definition.[详细]
2022-12-21 02:54 分类:问答Upgrading FParsec: upgrade discriminated unions to satisfy the new equality/comparison constraints
So, by a hilarious series of events, I downloaded the FParsec source and tried to build it. Unfortunately, it\'s not compatible with the new 1.9.9.9. I fixed the easy problems, but there are a couple[详细]
2022-12-21 01:08 分类:问答Getting a typed array from a discriminate union of different types of arrays in F#
If I have a discriminate union of different types of arrays how can i convert them to their \'actual\' types?[详细]
2022-12-14 08:14 分类:问答