[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message]

static typing of XQuery?

Mike Carey mcarey at bea.com
Wed Sep 20 22:14:18 PDT 2006


  static typing of XQuery?
BEA also does optimistic static typing. 

-----Original Message-----
From: http://x-query.com/mailman/listinfo/talk [mailto:http://x-query.com/mailman/listinfo/talk] On
Behalf Of Per Bothner
Sent: Wednesday, September 20, 2006 12:45 PM
To: Michael Kay
Cc: http://x-query.com/mailman/listinfo/talk
Subject: Re:  static typing of XQuery?

Michael Kay wrote:
 > Per Bothner wrote:
>> How much interest is there in the "static typing" feature?
> 
> There seem to be two clusters of interest in it: (a) Microsoft, and
(b)
> academics.

Interesting; I didn't realize Microsoft was so interested.  The FS
specification lists 2 Microsoft names, which is the same as the
number of IBM names, so for outsiders it would not be obvious.

> I think that schemaless data is an important use case, and in my view
> pessimistic static typing is unusable with schemaless data.

My thinking, too.

> Doing pessimistic static typing for schema-aware queries is more
reasonable,
> but there are still many cases where intermediate results are likely
to be
> untyped. My advice would be to steer well clear.  Optimistic static
typing
> (reporting errors only where the static type is disjoint from the
required
> type), as implemented in Saxon, seems to be quite good at catching a
wide
> class of programming mistakes.

Does Saxon implement full "optimistic static typing" or just some ad-hoc
subset?  By the former I mean the type system of the FS but, but with
more lenience ("optimism")?  If so, it seems that implementing full
static type checking should not be difficult.

My feeling (which seems to match yours) is that optimistic static
typing is useful and should perhaps be the default (pending further
experience), but pessimistic/strict typing would be nice to have as an
option for those who want it, but should not be the default.
-- 
	--Per Bothner
http://x-query.com/mailman/listinfo/talk   http://per.bothner.com/
_______________________________________________
http://x-query.com/mailman/listinfo/talk
http://x-query.com/mailman/listinfo/talk



Purchase Stylus Studio Online Today!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.