comp.lang.ada
 help / color / mirror / Atom feed
* Grace.Config_Files comment syntax
@ 2003-06-27 13:01 Stephen Leake
  2003-06-27 13:19 ` Vinzent Hoefler
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Leake @ 2003-06-27 13:01 UTC (permalink / raw)


David Koogler has expressed an interest in getting comments working in
Grace.Config_Files (see http://www.nongnu.org/Grace/Grace_Home.html;
I've just improved it, and added the Config_Files requirements).

The Config_Files requirements that we worked on here last year state
that the Config_Files file format is the same as the Java Properties
file format. Here's a reference for that:

http://java.sun.com/j2se/1.4.1/docs/api/java/util/Properties.html

(it's not very long, and the file format details are given in the
documentation of the "load" method; go read it :).

That says that comments are introduced by either "#" or "!", and
terminated by end of line. Also, comments must be alone on a line;
only whitespace can precede the comment symbol. That allows "#" and
"!" in value strings without an escape mechanism.

David also wants comments on the same line as a key/value pair. I
think that's a bad idea, both because it is incompatible with the Java
Properties definition, and because it complicates parsing the file.

Unless someone has an objection, I'll incorporate this syntax for
comments into the Config_Files requirements.

There are other details of the Java Properties format that we don't
currently follow; it provides a line continuation mechanism, allows
either "=" or ":" for the key/value separator, and uses C escape
characters in the value string. Anyone think those should be in
Config_Files? We did say one advantage of picking a predefined format
was interoperability; if we really believe that, we should simply
adopt this definition completely.

-- 
-- Stephe



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Grace.Config_Files comment syntax
  2003-06-27 13:01 Grace.Config_Files comment syntax Stephen Leake
@ 2003-06-27 13:19 ` Vinzent Hoefler
  2003-06-27 17:33   ` Stephen Leake
  0 siblings, 1 reply; 4+ messages in thread
From: Vinzent Hoefler @ 2003-06-27 13:19 UTC (permalink / raw)


Stephen Leake wrote:

>Unless someone has an objection, I'll incorporate this syntax for
>comments into the Config_Files requirements.

Don't forget the "--" comment. :-)


Vinzent.
-- 
Parents strongly cautioned  --  this  posting  is  intended for mature
audiences  over  18.  It  may  contain some material that many parents
would not find suitable for children and may include intense violence,
sexual situations, coarse language and suggestive dialogue.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Grace.Config_Files comment syntax
  2003-06-27 13:19 ` Vinzent Hoefler
@ 2003-06-27 17:33   ` Stephen Leake
  2003-06-28  7:49     ` Vinzent Hoefler
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Leake @ 2003-06-27 17:33 UTC (permalink / raw)


Vinzent Hoefler <ada.rocks@jlfencey.com> writes:

> Stephen Leake wrote:
> 
> >Unless someone has an objection, I'll incorporate this syntax for
> >comments into the Config_Files requirements.
> 
> Don't forget the "--" comment. :-)

Hmm. I see the smiley, but seriously, if we are following the Java
Properties file format, we can't add a new comment syntax.

Are you seriously suggesting that we should add a new comment syntax?

-- 
-- Stephe



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Grace.Config_Files comment syntax
  2003-06-27 17:33   ` Stephen Leake
@ 2003-06-28  7:49     ` Vinzent Hoefler
  0 siblings, 0 replies; 4+ messages in thread
From: Vinzent Hoefler @ 2003-06-28  7:49 UTC (permalink / raw)


Stephen Leake wrote:

>Vinzent Hoefler <ada.rocks@jlfencey.com> writes:
>
>> Don't forget the "--" comment. :-)
>
>Hmm. I see the smiley,

Yes. It wasn't meant to be *really* serious.

>but seriously, if we are following the Java
>Properties file format, we can't add a new comment syntax.

What a pity...

>Are you seriously suggesting that we should add a new comment syntax?

Well, if we'd do, would it break something? If the goal is to keep
100% compatibility in both directions, we can't do that, sure.


Vinzent.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-06-28  7:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-27 13:01 Grace.Config_Files comment syntax Stephen Leake
2003-06-27 13:19 ` Vinzent Hoefler
2003-06-27 17:33   ` Stephen Leake
2003-06-28  7:49     ` Vinzent Hoefler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox