Arc Forumnew | comments | leaders | submitlogin
Accessing Racket from anarki
3 points by jsgrahamus 1948 days ago | 9 comments
So this works:

  arc> ($:pair? '(1))
But this does not (verified in plain Racket):

  arc> ($:first '(1 2))
  first: undefined;
 cannot reference an identifier before its definition
    in module: "/home/steve/anarki/ac.scm"


How come?


4 points by akkartik 1947 days ago | link

Just to summarize rocketnia's and Oscar-Belletti's investigations on this thread, do this:

  arc> ($:require racket/list)
  arc> ($:first '(1 2))


3 points by akkartik 1948 days ago | link

My guess is that it's because even though Arc uses Racket, it's still using its legacy MzScheme language. This works, though:

  arc> ($:car '(1 2))
Though I'm not sure where we can find MzScheme-specific documentation anymore..


4 points by Oscar-Belletti 1947 days ago | link

I think you are right: the file ac.scm starts with:

    (module ac mzscheme
MzScheme doesn't have first.

On the wayback machine I found the docs of 2008 for MzScheme version 372:

There are still MzScheme docs here: but the links on that page don't work for me, so I found the page on the wayback machine(2009) too:


4 points by rocketnia 1947 days ago | link

There should be up-to-date reference information about the mzscheme library here:

As described there, mzscheme exports most of the bindings of racket/base. As described at, first is exported by racket/list and racket, but not by racket/base.

(My point isn't to say "you should have known" but to point out what the current documentation is like in case it's helpful for other reasons. XD )


2 points by Oscar-Belletti 1947 days ago | link

You are right. Sorry for the outdated links.


1 point by rocketnia 1947 days ago | link

Er, I upvoted your "sorry" just now because I did find it interesting that those archive links exist. :) I guess the Racket project doesn't have such tireless devotion to documentation that they maintain active versions of the docs for old software releases, but it's nice that a snapshot is up somewhere.


2 points by akkartik 1947 days ago | link

Nice work!


1 point by Oscar-Belletti 1947 days ago | link



4 points by jsgrahamus 1946 days ago | link

Thanks, guys. This is great!`