Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Jul 21st, 2011  |  syntax: F#  |  size: 0.23 KB  |  views: 162  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
This paste has a previous version, view the difference. Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. type FuncType<'a, 'b, 'c> = FuncType of ('b -> 'c)
  2.  
  3. let dummy<'a> (x:int) = Unchecked.defaultof<int>
  4.  
  5. let makeFunc (typ:FuncType<'a, 'b, 'c>) =
  6.  let (FuncType f) = typ
  7.  fun (_:'a) -> f
  8.  
  9. let f2 = makeFunc (FuncType(dummy<int>))