[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Syntax/matching rule implementation - floating point numbers



Lorenzo Pastrana writes:
>>> I'll be looking for some way of memcmp-arable real scalar encoding to
>>> see what's being done in networked games for example ...
>> 
>> Depending on your needs you could implement it without indexing support,
>> or at least with only EQUALITY indexing support.
> 
> Actually this is where floats are inherently bat at ...

Hmm, true.  Yet if you are going to have matching rules at all, you need
an EQUALITY rule.  (You can have attributes without matching rules, then
you can't use them in filters other than presence filters but you can
still read them.)

>>   No need for memcmpable ordering.
> 
> This is where fixed point reals can come handy ...
> I don't know what the applicable standard says about real numbers in
> LDAP but from what you say my bet is fixed-point reals could fit
> well ...

Well, the LDAP standard doesn't say anything.  However LDAP is based on
X.500, which has ASN.1 types plus some others.

But there's nothing to stop you from implementing a type with your
preferred semantics instead of whatever X.500 says.  Except perhaps
"whatever X.500 says" is already well thought through, so it might be a
good idea for that reason.

-- 
Hallvard