[classad-users] Bug related to keywords


Date: Thu, 16 Jun 2005 13:07:28 -0700
From: "Swaroop Sayeram" <swaroop@xxxxxxxxxx>
Subject: [classad-users] Bug related to keywords

Hello Folks,

I Just discovered a discrepancy regarding keyword parsing/unparsing when they happen to be identifiers.

 

I might be using an older version of the library, & maybe the classad developers have already fixed this issue. But let me run it through you guys anyway.

 

The issue is –

If we have a classad:

[‘error’ = 1]

In spite of the attribute name being a keyword the parsing succeeds because the name is quoted.

However when the ClassAd gets Unparsed, it spits it out as:

[error = 1]

Now if we try to parse this again, the parser bails out.

 

I’ve fixed this issue in both the Java & C++ libraries by getting the unparser to spit it out with single-quotes.

However, Im wondering, if that’s the best solution.

Would you rather have the parser succeed if it encountered “[error = 1]”, because the keyword is actually an attribute-name & hence the parser shouldn’t mind it.

 

Thanks,

 

 

Swaroop Sayeram

Member of Technical Staff

Direct : +1.408.321.9000  Ext:227

Fax    : +1.408.321.9030

Mobile: +1.408.242.1692

swaroop@xxxxxxxxxx

 

Optena Corporation

2860 Zanker Road, Suite 201

San Jose, CA 95134
www.optena.com

 

This electronic transmission (and any attached documents) contains information from Optena Corporation and is for the sole use of the individual or entity it is addressed to. If you receive this message in error, please notify me and destroy the attached message (and all attached documents) immediately.

 

[← Prev in Thread] Current Thread [Next in Thread→]