[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GLPK API change
From: |
John W. Eaton |
Subject: |
Re: GLPK API change |
Date: |
Thu, 8 Feb 2007 15:52:42 -0500 |
On 8-Feb-2007, Michael Goffioul wrote:
| As I said, this is just un ungly patch, not intended to be applied. This
| is just to illustrate
| where things changed. In this case, what has changed is the type of
| mem_tpeak, which
| switched from int to ulong_t. This ulong_t type is defined as:
|
| typedef struct { unsigned int low, high; } ulong_t;
Ugh. Aren't types ending in _t reserved?
Anyway, I see the problem now. I suppose we could write a test to
check and see if ulong_t can be assigned to a double (I assume
assigning a struct to a double will always fail with an error). If
ulong_t is a struct, then we need a way to assign it to a double. Or
maybe we just edit gplk and remove the mem output. Is that value
really important for us?
| This type cannot be casted simply to a double. However, this type has
| the same layout
| as unsigned long long on my x86 computer. So the cast was the fastest
| and also most
| non-portable solution I tried to check it worked on my setup. Something more
| appropriate has to be used.
It would be more helpful if instead of posting "ugly" patches, you
would simply post a bug report explaining precisely what the problem
is, including the error messages or warnings from a compiler.
jwe