Hi Asumu,
> In particular, the code for class contracts explicitly installs a value for
> the
> inspector that doesn't allow inspection (there's a comment saying "No
> inspection").
Thanks for exploring this, at least I now know what's going on!
> But maybe it's worth revisiting this part
Thanks for the answer, rapid as always.
Jos
-Original Message-
From: Matthew Flatt [mailto:mfl...@cs.utah.edu]
Sent: miércoles, 02 de septiembre de 2015 2:11
To: Jos Koot
Cc: 'racket users'; jos.k...@gmail.com
Subject: Re: [racket-users] custom-print called twice?
The first call is to d
The first call is to detect sharing, and the second time is to actually
print.
For example, if you change `(constr 'y)` to
(define b (box #f))
(set-box! b (constr b))
b
then you'll see that the output starts with "#0=", because the first
pass detected that a "#0#" will be needed.
At Wed,
Question:
why is in the following example the custom-printer called twice?
#lang racket
(define n 0)
(letrec-values
(((printer)
(λ (obj port mode)
(set! n (add1 n))
(fprintf port "#" (name obj
((id constr pred acc mut)
(make-struct-type 'x #f 1 0 #f
(list (cons prop
The best solution is usually to avoid using Any when interoperating with
untyped code. Presumably you can describe a more specific type for this
case, such as an opaque type for the sql-null value.
Sam
On Tue, Sep 1, 2015, 3:03 PM 'John Clements' via Racket Users <
racket-users@googlegroups.com>
I’m trying to use the database library db with TR, and I’ve run into a problem
whose only workaround seems really nasty.
Specifically, it concerns vectors (or lists, presumably) that contain opaque
values. So, for instance, here’s foo1.rkt:
#lang racket
(provide return-a-list)
(struct my-stru
Hi Konrad,
On 2015-09-01 20:42:42 +0200, Konrad Hinsen wrote:
> Thanks for the reference, but my interpretation of this is different. I
> don't care about eq?, nor about testing how objects were created. I want
> comparison by equal? by recursive application to the fields - just as for
> transpare
On 01/09/15 18:45, Daniel Feltey wrote:
I think this is expected, if you want to check for equality on instances
of contracted classes you should use the `object=?` function which can
"see through" the contract wrappers.
http://docs.racket-lang.org/reference/objectutils.html?q=object%3D%3F#%28d
On Tue, Sep 1, 2015 at 10:03 AM, Ben wrote:
> Hi,
>
> I'm trying to build a web application using Racket. But I don't understand
> continuations yet. I think the package is capable of writing simple
> applications without continuations. So
>
> 1. Which part of the web-server package should I st
Hi everyone,
I am trying to add a contract to a class but find that the mere presence
of the contract breaks my code. Here is a minimal example that illustrates
the problem:
--
#lang racket
(define foo%
(class object%
(inspect #f)
(super-
Is there a way to check whether there is a message available to be
picked up on a place-channel without blocking?
(If there isn't, the only way forwards for me in Racket is via a server.
possibly a tcp server, though I don't really want the handshake.
Possibly a Unix Socket Server. Possibly
Hi,
I'm trying to build a web application using Racket. But I don't understand
continuations yet. I think the package is capable of writing simple
applications without continuations. So
1. Which part of the web-server package should I stay away from if I don't
want to use continuations?
2. Wh
The problem is that the documentation-build process cannot support a
use (direct or indirect) of `racket/gui/base` at documentation-build
time. The
@(require teachpacks/racket-turtle)
in your ".scrbl" files is the main problem, since that indirectly loads
`racket/gui/base`.
It looks like you we
Hi,
I uploaded my very first package and scribble docs to the Racket package
server. It seems that there is something wrong in my scribble files since the
docs don't show up and I get this error:
"cannot instantiate `racket/gui/base' a second time in the same process
context"?
Here is the who
14 matches
Mail list logo