4
let (**) ls1 ls2 = List.intersect ls1 ls2

does not work because (**) is considered a comment. Is there any escape possibility?

citykid
  • 9,916
  • 10
  • 55
  • 91

1 Answers1

7

You can add whitespace inside the parentheses, like this:

let ( ** ) ls1 ls2 = List.intersect ls1 ls2

Keep in mind, however, that ** is a standard F# operator for "power":

2 ** 3 = 8

So if you redefine it like this in the global context, you will not be able to use it in the "power" sense.

Fyodor Soikin
  • 78,590
  • 9
  • 125
  • 172