type Parameter =
| Fixed of double
| Free of double ref
with
override m.ToString() =
match m with
| Fixed v -> sprintf "%f" v
| Free v -> sprintf "$%f" v.Value
static member (~!) m =
match m with
| Fixed v -> v
| Free v -> !v
The operator I try to define ~!
causes the error but according to http://msdn.microsoft.com/en-us/library/dd233204%28VS.100%29.aspx !
is a valid prefix operator.
(~+)
works ok
The specific error is
Error FS1208: Invalid operator definition.
Prefix operator definitions must use a valid prefix operator name.
(FS1208) (SketchSolveFS)