[Versa] Versa issue: quote madness
Uche Ogbuji
uche.ogbuji at fourthought.com
Mon Aug 15 09:39:02 MDT 2005
On Mon, 2005-08-15 at 05:32 -0400, Chimezie Ogbuji wrote:
> On 8/15/05, Michael lson <Mike.Olson at fourthought.com> wrote:
> >
> > On Aug 12, 2005, at 10:32 PM, Uche Ogbuji wrote:
> >
> > > Quotes in Versa can get badly out of hand. I've commented on this
> > > before, but here's Kyle LeBlanc:
> > >
> > > http://lists.fourthought.com/pipermail/4suite/2004-October/012915.html
> > >
> > > I think that for Versa 2.0 we should find a better syntax for
> > > subexpressions, and that they should be promoted to first class
> > > constructs.
> > >
> > > Basically first class functions which are optionally anonymous.
> > >
> >
> > How about {}?
> >
> > So the idea is that any where a "expression" is require, if it is
> > wrapped in {} it would be evaluated in the current context?
>
> so to get all items with titles and labels that contain the word
> 'Cars' from the model:
>
> filter(
> all(),
> {. - dc:title -> contains('Cars')},
> {. - rdfs:label -> contains('Cars')},
> )
>
> ?
Perhaps, but I think we probably want at least some the power of LISP
macros, which would be something closer to Python lambdas with nested
scopes (and without the hacky scope semantics, but rather LISP's
parameter renaming approach).
In any case, this seems a strong 2.0 issue, so I'll expand on my own
suggestions soon.
> > If we go that far, I think we should change absolute URIs to match NT,
> > just to make life easier on all evolved.
> @'http://www.w3.org/2002/07/owl#Ontology' - rdfs:comment -> *
>
> becomes
>
> <http://www.w3.org/2002/07/owl#Ontology> - rdfs:comment -> *
>
> We would probably would want to preserve the original form for
> backward compatibility and deprecate it perhaps, but I think *most*
> moves toward N3 syntax are a good idea. This *might* cause the parser
> grammer problems with the '<' and '>' characters (if they are adopted
> as shorthand form for the lt and gt boolean operator functions).
I agree with this change (that notation is now in N3 as well as
NTriples), but I think it should be in 2.0, and then we don't care about
backwards compatibility (IOW current form becomes illegal in 2.0).
If we restrict < and > to numeric types (and even data typed literals in
the form ""^^), we should be OK with the ambiguity in the parser.
--
Uche Ogbuji Fourthought, Inc.
http://uche.ogbuji.net http://fourthought.com
http://copia.ogbuji.net http://4Suite.org
Use CSS to display XML, part 2 - http://www-128.ibm.com/developerworks/edu/x-dw-x-xmlcss2-i.html
XML Output with 4Suite & Amara - http://www.xml.com/pub/a/2005/04/20/py-xml.html
Use XSLT to prepare XML for import into OpenOffice Calc - http://www.ibm.com/developerworks/xml/library/x-oocalc/
Schema standardization for top-down semantic transparency - http://www-128.ibm.com/developerworks/xml/library/x-think31.html
More information about the Versa
mailing list