Code Monkey home page Code Monkey logo

define-library's People

Contributors

alvatar avatar feeley avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

define-library's Issues

Defaulting export of all defined names if (export) form is absent

Library:

(define-library (spheres/math/exact)
    (export double) ; <-- If commented, 
    (import (gambit))
    (begin
      (define double (λ (x) (* 2 x)))))

Code using the library:

(define-library (asdf) (import (gambit) (spheres/math/exact)) (begin (pp 'asdf)))

If (export) isn't used, then:

*** ERROR IN (console)@10.71 -- Unbound variable: spheres/math/exact#pp

Should the (export) clause be mandatory? If so, a warning/error should be emitted when absent.

'Empty' namespace not restored in REPL once the define-library form has been used

This might be intentional, but I believe that for seamless REPL integration of the new define-syntax form, this shouldn't happen:

> (load "define-library")
"/Users/Alvaro/define-library/define-library.o1"
> (define-library (asdf) (import (gambit)))
> (define-library (asdf) (import (gambit)))
*** ERROR IN (console)@3.2 -- Unbound variable: asdf#define-library
1> ,d

Setting namespace to empty solves it, if it is actually a bug.

> (##namespace (""))
> (define-library (asdf) (import (gambit)))

Just adding this form at the end of a define-syntax expansion should be fine, and seems to work in other tests.

macros support?

Looks current implementation completely ignored syntactic closure / syntax-rules, will any of these be in the road map? what about define-macro?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.