Arc Forumnew | comments | leaders | submitlogin
Escaping to mzscheme
11 points by kens 6164 days ago | 2 comments
I've discovered that you can access underlying mzscheme functions by using seval or $. This allows you to access Scheme's mathematical functions, for instance:

  arc> (seval '(asin 1))
  1.5707963267948966
  arc> (($ acos) 1)
  0
  arc> (= atan ($ atan))
  arc> (atan 1)
  0.7853981633974483
You can also do this with string functions:

  arc> (= x "hello")
  arc> (($ string-fill!) x #\a)
  arc> x
  "aaaaa"
I'm not sure if doing this is a good idea or a bad idea :-)


4 points by vincenz 6164 days ago | link

This is something that was introduced in the -git- version of Arc. It was something done by a few users in #arc. It is not part of the original language.

-----

2 points by cpfr 6164 days ago | link

Yea, we figured people would like to have scheme at their side. It certainly squashes the whole "Arc needs a standard library" talk.

-----