× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Gee, David, I never thought about nesting comments. However, after reading this, I tried it in a CLP using SEU and WDSc.

SEU accepted /*/* comment */, but barfed on /* /* comment */ */.

WDSc accepted /* /* comment */, but "auto-corrected" /* /* comment */ */ to
*/ /* /* comment */
*/ /* /* comment */

Jerry C. Adams
IBM System i Programmer/Analyst
--
B&W Wholesale
office: 615-995-7024
email: jerry@xxxxxxxxxxxxxxx


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of David Gibbs
Sent: Friday, January 08, 2010 2:37 PM
To: Midrange Systems Technical Discussion
Subject: Nested SQL Comment oddity

OK, I just encountered something very odd.

It appears that the RUNSQLSTM command considers comments, nested within comments, to be valid and requires them to be balanced.

For instance ... the following comment is *NOT* valid:

/* /* NESTED COMMENT */

While this comment IS valid:

/* /* NESTED COMMENT */ */

To my mind, this screams parser error ... language parsers should stop processing when they encounter the start of a comment and resume when they encounter the first end of comment marker.

Weird, eh?

david


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.