Code Monkey home page Code Monkey logo

infix's People

Contributors

alexknauth avatar mbutterick avatar soegaard avatar willghatch avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

infix's Issues

Using infix with variable string

i try to use the code:

#lang at-exp racket
(require infix)
(define txt "2+2")
@${ txt } or ($ "txt")

but the output it's the string "2+2" and not the evaluation @${2+2} or ($ "2+2") -> 4
it is posible to use a string as argument of $ to be evaluated as i need?

DrRacket renaming is doing weird things

If I have this program in DrRacket:

#lang at-exp racket
(require infix)
(let ([a '(1 1)] [b '(2 3)] [+ (λ (a b) (map + a b))])
  @${a+b})

And then I right-click on the a in @${a+b} then the check-syntax arrow points the the right thing, but the menu pops up with an option saying rename +, then if I proceed to rename it to, say -, then it changes it to:

(let ([- '(1 1)] [b '(2 3)] [- (λ (a b) (map + a b))])
  @${--b})

In other words, it renames both a and + to -.
Do you have any idea what could be causing this?

Direct string escapes with at-exp lead to wrong source locations

In programs like this:

#lang at-exp racket/base
(require infix)
(define x0 0)
(define v 5)
(define dt 1)
@${x@"0" + v*dt}

Because direct string escapes are handled specially by the at-exp reader, this expands directly to ($ "x0 + v*dt"), so it thinks the v and the dt are 3 characters before where they are.

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.