OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] bohemians, gentry

[ Lists Home | Date Index | Thread Index ]

On Thursday 05 December 2002 15:49, Uche Ogbuji wrote:

> Alaric B. Snell:
> > That's a big part of what typing can be for XML. Rather than a wooly
> > description that this element contains a date (the kind of typing that
> > happens in so-called "untyped" XML), instead referencing a formally
> > defined type.
>
> There is no reason that the bludgeon of type needs to be used to enforce
> lexical constraints.  If lexical constraints are what you need, it's better
> to just use, well, lexical constraints.

Lexical constraint is one form/aspect of typing things that are represented 
lexically... that's all the typing in XSD really does, although it does make 
the type information available for other uses too.

> > When the spec says that xs:decimal has 'arbitrary' precision it does not
> > (well, from other use of the same term in other contexts, *should* not)
> > mean:
> >
> > 1) That implementations can arbitrarily drop precision
>
> Umm.  It doesn't have to say this.  This is the simple reality.  If
> representing a particular decimal requires more resources than my machine
> has available, something has to give.

An arbitrary precision library faced with a number too large to represent in 
memory ought to throw out of memory exceptions rather than dropping digits...

Ok, from your apparent ignorance of these things, I take it you've never 
really worked with real implementations of arbitrary precision numbers (which 
have been around since the LISP days, and Java currently has one in the 
standard libraries) so please stop making absolute statements about them that 
aren't true!

> > 2) That implementations have to allocate all available memory for the
> > buffer
>
> I didn't say they had to.  I was using a bit of reductio to hack at
> Jonathan's point that knowing in advance that they can be "arbitrary" is of
> any use.

They are as arbitrary as the length of CDATA in elements in XML. I'd hate to 
use any XML processing software you have written if you take 'arbitrary' to 
mean 'If it is too big to fit into memory I can just drop characters because 
the length is ARBITRARY' :-)

> > As any decent programmer will tell you, arbitrary precision types are so
> > named because they give the *user* arbitrary precision, and if the
> > machine doesn't have enough memory to represent what the user provides
> > then it's the same problem as when a Java String type is told to handle a
> > piece of text too large to fit into virtual memory, no more no less.
>
> Any decent reader will teach you how to follow an argument.  Try it next
> time.

Nya nya nya! Well *my* dad's superman!

ABS

-- 
A city is like a large, complex, rabbit
 - ARP




 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS