[plt-scheme] abstracting over (PLaneT) requires

From: Jay McCarthy (jay.mccarthy at gmail.com)
Date: Mon Dec 1 13:50:03 EST 2008

Here's a simple way:

my-lib.ss:
(require (planet "some-file.ss" ("joe" "a-package.plt" MAJOR (= MINOR))))
(provide (all-from-out (planet "some-file.ss" ("joe" "a-package.plt"
MAJOR (= MINOR)))))

my-old-other-lib.ss:
(require (planet "some-file.ss" ("joe" "a-package.plt" MAJOR (= MINOR))))

my-other-lib.ss:
(require "my-lib.ss")

Jay

On Mon, Dec 1, 2008 at 11:38 AM, Rob Hunter <rob.hunter at gmail.com> wrote:
> Is there any way to abstract over requires?  In particular, I'm
> interested in abstracting over the version of a PLaneT package that I
> require.  Something like
>
>  (require (planet "some-file.ss" ("joe" "a-package.plt" MAJOR (= MINOR))))
>
> where MAJOR and MINOR could be bound in exactly one spot.  Thus, I
> could easily do a system-wide change of which version of a-package.plt
> I am including.
>
> Thanks!
>
> Rob
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme
>



-- 
Jay McCarthy <jay at cs.byu.edu>
Assistant Professor / Brigham Young University
http://jay.teammccarthy.org

"The glory of God is Intelligence" - D&C 93


Posted on the users mailing list.