From: Erik de Castro Lopo <mle+ocaml@mega-nerd.com>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Val_int vs caml_copy_nativeint
Date: Mon, 8 Aug 2011 17:49:03 +1000 [thread overview]
Message-ID: <20110808174903.ec7927c968f82ca05d35025f@mega-nerd.com> (raw)
In-Reply-To: <20110808035901.GJ29083@localhost>
Guillaume Yziquel wrote:
> Given that Val_int is Val_long (in mlvalues.h):
>
> #define Val_int(x) Val_long(x)
>
> it's not an issue with this piece of code.
>
> But depending on what "doesn't work" means and on the declarations of
> width and height, then sizeof(int) < sizeof(long) may explain the issue.
The width and height variables are both defined as int and I'm working
on 32 bit Linux.
Doesn't work means I don't get the value I think I should (small integers
in the range [16, 144]) but rather gte values that look more like pointers.
Erik
--
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/
next prev parent reply other threads:[~2011-08-08 7:49 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-08 3:15 Erik de Castro Lopo
2011-08-08 3:48 ` Romain Beauxis
2011-08-08 3:59 ` Guillaume Yziquel
2011-08-08 7:49 ` Erik de Castro Lopo [this message]
2011-08-08 3:53 ` Guillaume Yziquel
2011-08-08 7:46 ` Erik de Castro Lopo
2011-08-08 8:03 ` Guillaume Yziquel
2011-08-08 9:17 ` Mathias Kende
2011-08-08 17:24 ` Xavier Leroy
2011-08-09 1:33 ` Erik de Castro Lopo
2011-08-09 1:40 ` Romain Beauxis
2011-08-09 8:44 ` David Allsopp
2011-08-09 10:07 ` malc
2011-08-09 10:43 ` David Allsopp
2011-08-09 22:53 ` Erik de Castro Lopo
2011-08-10 6:43 ` Gabriel Scherer
2011-08-08 5:20 ` malc
2011-08-08 6:01 ` Guillaume Yziquel
2011-08-08 6:22 ` malc
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110808174903.ec7927c968f82ca05d35025f@mega-nerd.com \
--to=mle+ocaml@mega-nerd.com \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox