2

Can someone help me with frege equivalent of import command in haskell for Data. I wish to access Data.Typeable or Data.Time.Calendar.....and such modules/inbuilt procedures.

Do we have a way to know the available modules in frege.....like in general if I do "import.frege._" is there any autofill kind of feature or list of some sort suggesting the various options available.

thanks a lot for your time and help

skg
  • 23
  • 3
  • The autofill feature in eclipse is now available fro some time. Also, the online docs available under http://www.frege-lang.org/doc/fregedoc.html should provide a good overview what is there in the standard distribution. – Ingo Oct 08 '15 at 22:42

2 Answers2

1

Sorry, none of the modules you want are implemented yet at this time.

To see what is available follow the link standard libraryon the frege project page.

Remember that a package name like Data.Typeable is short for frege.data.Typeable hence you would have to look for Typeable.html in subdirectory data.

There is also no autofill capability yet (in the eclipse plugin).

Janus Lynd
  • 209
  • 1
  • 8
Ingo
  • 36,037
  • 5
  • 53
  • 100
1

I already had a look at Haskell's date and time libraries, and I have to say the amount of work to translate this is daunting. Java's built-in date and time support is terrible, and while other Java libraries (Joda Time, JSR 310) better, but quite voluminous, and fit only partially in a pure language. I tried to start with a simple date (without time) module, but it is still buggy. I haven't looked into this problem for some time, but people asking for it is motivating.

Concerning other missing libraries I really encourage you to try to translate them at least partially yourself, it's often not as hard as it looks. Most code can be translated "mechanically", the main problem is usually that other, referred modules are missing, too.

Landei
  • 54,104
  • 13
  • 100
  • 195
  • It's often not as hard - yes, as long as it is Haskell 2010. GHC with certain extensions concerning the type system is another story. (I know you know this, just noting it here for prospective porters.) – Ingo Aug 18 '12 at 15:41