Print_int and other F # print functions

I'm trying to make a simple tutorial in Visual Studio let someNumber = (2 + 2) print_int someNumber but it says print_int is undefined. printfn works. Could the book I'm using be out of date?

+1


source to share


2 answers


print_int is part of the F # power supply. Adding a link to PowerPack (c: \ program files \ FSharp-1.9.6.2 \ bin \ FSharp.PowerPack.dll on my machine) should fix the problem.

Here's a blog post from Don that mentions the current Power Pack plans:



http://blogs.msdn.com/dsyme/archive/2008/12/10/fsharp-to-ship-as-part-of-visual-studio-2010.aspx

+3


source


Actually, print_int is not in FSharp.PowerPack.dll, at least not in the latest version (PowerPack version 1.9.9.9). It's in FSharp.PowerPack.Compatibility.dll.

FYI to use print_int, print_endline, etc. in the F # Interactive window (and disable ML compatibility warnings), use the following commands:



#r "FSharp.PowerPack.Compatibility.dll";;
#nowarn "62";;

      

0


source







All Articles