Hi Dmitry,
> You may remember me from this topic:
> https://groups.google.com/forum/#!topic/racket-users/E6utg2Pv5hA where
> I looked for a scientific language and a tool for code generation.
Yes, I remember!
> Leibniz seems to be very general. Is generation of (C or other) code
> from Leibniz o
This nightmarish but organic example produced by a student actually works
correctly, and is a beautiful example of why we need teaching languages (or a
type system that enforces boolean inputs to ‘or’):
https://www.brinckerhoff.org/blog/
Note that while the actual student code is in python, it’
I would also like to know more about this topic. I have never done any
rigorous tests, however for my application which takes about 7 seconds to load,
I have observed the following:
* there is no big startup difference between running the application as "racket
run.rkt" (which loads the alread
On Thu, Apr 27, 2017 at 12:34 PM, Vishesh Yadav wrote:
>
>> BTW: I'm interested in porting to RacketScript. How does the performance
>> of the image library equivalent compare with regular Racket?
>>
>>
> It is slower than regular Racket. I did not spend much time comparing it
> with Racket, and
>
>
> BTW: I'm interested in porting to RacketScript. How does the performance
> of the image library equivalent compare with regular Racket?
>
>
It is slower than regular Racket. I did not spend much time comparing it
with Racket, and there is definitively scope for improvement. Let us know
how po
Thanks, that does the trick!
-Philip
On Wed, Apr 26, 2017 at 6:27 PM, Matthew Flatt wrote:
> The `all-defined-out` macro supports a trick that several non-hygienic
> macros use: it uses the scopes on the parentheses around
> `all-defined-out` non-hygienically, instead of the scopes on the
> ide
The `all-defined-out` macro supports a trick that several non-hygienic
macros use: it uses the scopes on the parentheses around
`all-defined-out` non-hygienically, instead of the scopes on the
identifier.
So, in place of
(datum->syntax stx '(all-defined-out)))
you can use
(datum->syntax stx `
I'm working on a #%module-begin variant that provides all module-level
bindings, and I'm having trouble finding the right way to give lexical
context to all-defined-out.
The issue (IIUC) is that all-defined-out only exports identifiers "that
have the same lexical context as the (all-defined-out) f
Hi,
This sounds like a nice enhancement.
You might want to request this at https://github.com/racket/scribble/issues .
Aside from the implementation difficulty (the code for defform and friends is
large, handles many edge cases, and feels a bit like spaghetti code), one of
the main concerns wo
Hi all!
Some of my libraries take a while to load: just adding a (require mylib) to an
empty #lang racket/base file bumps the compile time from 0.5s to 1.5s, even if
no bindings from the library are used. After experimenting a bit, it seems that
the overhead is mainly due to other modules which
Konrad,
Sorry I am a bit late to the party.
You may remember me from this topic:
https://groups.google.com/forum/#!topic/racket-users/E6utg2Pv5hA
where I looked for a scientific language and a tool for code generation.
Leibniz seems to be very general. Is generation of (C or other) code from
L
On Wednesday, April 26, 2017 at 9:48:56 AM UTC-7, David K. Storrs wrote:
> On Wed, Apr 26, 2017 at 12:21 AM, Jon Zeppieri wrote:
> I don't know that there's a right way, but if your functions are
>
> nullary, then promises are a decent fit:
>
>
>
> (define conf
>
> (delay
>
> (with-inp
On Wed, Apr 26, 2017 at 12:48 PM, David Storrs wrote:
>
>
> On Wed, Apr 26, 2017 at 12:21 AM, Jon Zeppieri wrote:
>>
>> I don't know that there's a right way, but if your functions are
>> nullary, then promises are a decent fit:
>>
>> (define conf
>> (delay
>> (with-input-from-file ...)))
>
On Wed, Apr 26, 2017 at 12:21 AM, Jon Zeppieri wrote:
> I don't know that there's a right way, but if your functions are
> nullary, then promises are a decent fit:
>
> (define conf
> (delay
> (with-input-from-file ...)))
>
> Then just (force conf) whenever you want the value.
>
Yeah, that
Alexander McLin writes:
> One paper I have in mind is Hodgkin & Huxley's paper published in 1952
> where they first wrote down the equations describing the membrane
> voltage of the giant squid
> axon.
> https://www.ncbi.nlm.nih.gov/pmc/articles/PMC1392413/pdf/jphysiol01442-0106.pdf
>
> It'll be
#lang racket
(define read-conf
(let [(conf (delay (with-input-from-file “db.conf" (thunk (displayln "hello")
(read)]
(thunk
(force conf
(read-conf)
(read-conf)
--
You received this message because you are subscribed to the Google Groups
"Racket Users" group.
To unsubscrib
On Wednesday, April 26, 2017 at 5:21:41 AM UTC+1, Jon Zeppieri wrote:
> (define conf
> (delay
> (with-input-from-file ...)))
>
> Then just (force conf) whenever you want the value.
I tend to call promises xxx-promise (e.g. conf-promise),
to remind me not to use them without force'ing them.
Greetings.
On 25 Apr 2017, at 23:51, 'John Clements' via Racket Users wrote:
In answer to your actual question, the most common name is “Tail
Call Optimization,” which many people correctly object to because
it’s not an optimization, it’s a change to the meaning of terms in
the language
I'
A `define/delay` macro for this might be a good addition to `racket/promise`:
(define-simple-macro (define/delay id:id expr:expr)
(begin (define p (delay expr)) (define (id) (force p
(define/delay conf
(with-input-from-file "db.conf" read-json))
(conf) ;; forces promise
--
You received
Thank-you all for the suggestions. I'll check them out and report back.
Vishesh: There is some repetition (not animation), but I removed all
caching to simplify and rework the interactive flow. It would be with
trying freeze in conjunction with updated caching.
BTW: I'm interested in porting to R
20 matches
Mail list logo