Hi Ben Greenman
Unsyntaxed elemtag and elemref work well in code:comment.
I did this as follows:
#lang scribble/manual
@require[scribble/example]
@(define my-eval (make-base-eval))
Beginning.
@examples[#:eval my-eval
(code:comment #,(elemtag "plus2" ""))
(define (plus2 n)
(+ 2 n))
Hi Taahir,
The keyword is #:replacement? instead of #:replacement (note the
question mark). I don't know enough Typed Racket to understand that
error message tho, sorry.
Cheers,
Shu-Hung
On Tue, Oct 3, 2017 at 1:40 AM, Taahir Ahmed wrote:
> Hi,
>
> I have been implementing some toy problems in
Of course it's something simple like that. You are correct, I changed
it to `#:replacement?` and then the program typechecked and ran.
It would be helpful if the error message showed me that I was passing
extra arguments in the domain of the function, but at least now I know
what was happening.
Yes, that's definitely a bad error message, so we should try to
improve Typed Racket here.
Sam
On Tue, Oct 3, 2017 at 12:54 PM, Taahir Ahmed wrote:
> Of course it's something simple like that. You are correct, I changed
> it to `#:replacement?` and then the program typechecked and ran.
>
> It w
hello,
how do i access the pattern variable var at compile time (phase 1?)
additional to an answer, could you point me to the right part of the
documentation? i really couldn't find it.
#lang racket
(define inp (open-input-string "12+34"))
(define-syntax (terminal stx)
(syntax-case stx ()
> On Oct 3, 2017, at 10:31 AM, 'Shakin Billy' via Racket Users
> wrote:
>
> how do i access the pattern variable var at compile time (phase 1?)
> additional to an answer, could you point me to the right part of the
> documentation? i really couldn't find it.
`var` isn't a `procedure?` during
Thanks a lot.
Am 03.10.2017 9:05 nachm. schrieb "Matthew Butterick" :
>
> > On Oct 3, 2017, at 10:31 AM, 'Shakin Billy' via Racket Users <
> racket-users@googlegroups.com> wrote:
> >
> > how do i access the pattern variable var at compile time (phase 1?)
> > additional to an answer, could you poi
> On Oct 1, 2017, at 12:50 PM, Jordan Johnson wrote:
>
> Correct me if I’m wrong in this understanding: the #'(module ...) is
> effectively replacing the body of whatever program is written in #lang
> mylang, so the path-string "semantics.rkt" must be interpreted relative to
> that program’s
I'm dealing with some foreign apis that want to be passed long lived output
pointers to structs. The apis eventually call back indicating that the
struct has been filled in appropriately and then I want to read out the
values and deallocate the structs. I'm using atomic interior memory for
these st
Is the work to parse out the values short enough that you can do it
atomically in response to the notification that says the data is ready?
If so, it's probably best to parse and free in atomic mode. Or can you
at least atomically separate out references to children, where
finalizers can sensibly b
Parsing it out in atomic mode probably will work, I'll look at that. The
callback method I described is actually not how it works, and it is a bit
more complicated (involving a separate place and blocking foreign calls),
but I can do all of the decomposing work in atomic mode. I think I'm
avoiding
I've actually simplified my program that causes the issues and it doesn't
need the callback or the foreign functions at all it just needs structs
with substructs.
This shows that if garbage is collected after making the substruct is
complete then the finalizer gets run, which trashes the memory I'
12 matches
Mail list logo