Re: Language Versions

2022-09-15 Thread Akim Demaille
Arthur,

> Le 15 sept. 2022 à 22:59, Arthur Schwarz  a écrit :
> 
>> Hi;
>> 
>>> This is no more than a single line in the document and/or part of --help. 
>>> It tells your audience what compilers they can use and what language 
>>> elements are available. All with a single line.
>> 
>> No can do.  That's something related to the skeletons.  So I will complete 
>> their documentation, yes.
> 
> This puzzles me. You can't put a single line in for each language telling the 
> user what the baseline language is?

Yes, sorry, that was indeed a poor choice of word.

I meant "No, I don't want to do that".

Currently --help says nothing about the existing skeletons, and I don't want to 
start.  That's rather something belongs to the documentation.

> I don't believe this has anything to do with the skeletons,

Yes it does.

> unless the skeletons are linked to a different language,

Yes they are.

> and in this case the baseline language is the language version for the 
> skeleton. I am truly mystified. You have already said what the Bison language 
> version choices are (see below), what is being asked for is that  you include 
> them in the manual. Something like, "Bison output is compilable using version 
> C(), C++(), and D()", where the language version used is inserted in the 
> "()". You might need to use prettier words but the sense is that you know the 
> answer, and the user's of Bison should know it also.

Again, I agree you do have a point, and I will write some documentation about 
that.  However, I can't remember someone complaining about the targeted 
language of a given skeleton, so your point is somewhat theoretical.

Cheers.


Re: Language Versions

2022-09-15 Thread Arthur Schwarz

Hi;


This is no more than a single line in the document and/or part of --help. It 
tells your audience what compilers they can use and what language elements are 
available. All with a single line.


No can do.  That's something related to the skeletons.  So I will complete 
their documentation, yes.


This puzzles me. You can't put a single line in for each language 
telling the user what the baseline language is? I don't believe this has 
anything to do with the skeletons, unless the skeletons are linked to a 
different language, and in this case the baseline language is the 
language version for the skeleton. I am truly mystified. You have 
already said what the Bison language version choices are (see below), 
what is being asked for is that  you include them in the manual. 
Something like, "Bison output is compilable using version C(), C++(), 
and D()", where the language version used is inserted in the "()". You 
might need to use prettier words but the sense is that you know the 
answer, and the user's of Bison should know it also.


Perpetually Confused;
art

On 9/9/2022 11:52 PM, Akim Demaille wrote:

Hi Arthur,


Le 6 sept. 2022 à 23:05, Arthur Schwarz  a écrit :

Hi Akim;

I do mean the version of C/C++/D/Java should be stated.

It does make sense.


For example int he C case there is the K & R version.

We aim at C90.  KnR support was dropped long ago:


* Noteworthy changes in release 2.6 (2012-07-19) [stable]

** Future changes

   The next major release of Bison will drop support for the following
   deprecated features.  Please report disagreements to bug-bi...@gnu.org.

*** K C parsers

   Support for generating parsers in K C will be removed.  Parsers
   generated for C support ISO C90, and are tested with ISO C99 and ISO C11
   compilers.

And I can't remember anyone complaining about that.


Is this the relatively old version you mean. For C++ do  you mean C++98, C++03, 
C++11?

My first sentence was unclear, but contained the answer: C++98.  And compatible 
with more recent versions of the language. At some point I suppose we will be 
able to drop C++03 and require at least C++11, but there's no urge for this.


All of these are relatively old.I expect that D and Java have the same 
uncertainty.

That you use relatively old versions is meaningless because you haven't 
specified the version. And suppose that the version baseline changes, and code 
generated from prior versions are deprecated, or more insidious, the semantics 
are altered. You've provided no guidance.

What are you exactly referring to here?  I am not aware of any case where the 
semantics are actually altered.

I do agree the skeletons should specific their language requirements, you are 
absolutely right.  But I dispute that changing the target language version 
(e.g. KnR to C90) ever changed some semantics.  It certainly broke builds for 
people who were still using KnR C in 2012, but it did not alter semantics in 
practice.



This is no more than a single line in the document and/or part of --help. It 
tells your audience what compilers they can use and what language elements are 
available. All with a single line.

No can do.  That's something related to the skeletons.  So I will complete 
their documentation, yes.

Cheers!




Re: Language Versions

2022-09-10 Thread Akim Demaille
Hi Arthur,

> Le 6 sept. 2022 à 23:05, Arthur Schwarz  a écrit :
> 
> Hi Akim;
> 
> I do mean the version of C/C++/D/Java should be stated.

It does make sense.

> For example int he C case there is the K & R version.

We aim at C90.  KnR support was dropped long ago:

> * Noteworthy changes in release 2.6 (2012-07-19) [stable]
> 
> ** Future changes
> 
>   The next major release of Bison will drop support for the following
>   deprecated features.  Please report disagreements to bug-bi...@gnu.org.
> 
> *** K C parsers
> 
>   Support for generating parsers in K C will be removed.  Parsers
>   generated for C support ISO C90, and are tested with ISO C99 and ISO C11
>   compilers.

And I can't remember anyone complaining about that.

> Is this the relatively old version you mean. For C++ do  you mean C++98, 
> C++03, C++11?

My first sentence was unclear, but contained the answer: C++98.  And compatible 
with more recent versions of the language. At some point I suppose we will be 
able to drop C++03 and require at least C++11, but there's no urge for this.

> All of these are relatively old.I expect that D and Java have the same 
> uncertainty.
> 
> That you use relatively old versions is meaningless because you haven't 
> specified the version. And suppose that the version baseline changes, and 
> code generated from prior versions are deprecated, or more insidious, the 
> semantics are altered. You've provided no guidance.

What are you exactly referring to here?  I am not aware of any case where the 
semantics are actually altered.

I do agree the skeletons should specific their language requirements, you are 
absolutely right.  But I dispute that changing the target language version 
(e.g. KnR to C90) ever changed some semantics.  It certainly broke builds for 
people who were still using KnR C in 2012, but it did not alter semantics in 
practice.


> This is no more than a single line in the document and/or part of --help. It 
> tells your audience what compilers they can use and what language elements 
> are available. All with a single line.

No can do.  That's something related to the skeletons.  So I will complete 
their documentation, yes.

Cheers!


Re: Language Versions

2022-09-06 Thread Arthur Schwarz

Hi Akim;

I do mean the version of C/C++/D/Java should be stated. For example int 
he C case there is the K & R version. Is this the relatively old version 
you mean. For C++ do  you mean C++98, C++03, C++11? All of these are 
relatively old.I expect that D and Java have the same uncertainty.


That you use relatively old versions is meaningless because you haven't 
specified the version. And suppose that the version baseline changes, 
and code generated from prior versions are deprecated, or more 
insidious, the semantics are altered. You've provided no guidance.


This is no more than a single line in the document and/or part of 
--help. It tells your audience what compilers they can use and what 
language elements are available. All with a single line.


Cheers;
art

On 9/4/2022 1:35 AM, Akim Demaille wrote:

Hi,


Le 11 juin 2022 à 00:52, slipbits  a écrit :

Could you specify the language version of the generated parser code? This will 
help in specifying the correct compiler to use for the generated parser source 
code and headers.

You mean that we should specify that C++ means C++98, C C90, etc.?

We aim to relatively old versions of the various standards.

For Java, the test suite uses Java 1.7, but we might support older versions of 
Java, I actually don't know.

Wrt to D, I have no idea how generations/versions of the language are specified.



Concretely, what problem did you have to fix that would have been solved by 
more documentation?




Re: Language Versions

2022-09-04 Thread Akim Demaille
Hi,

> Le 11 juin 2022 à 00:52, slipbits  a écrit :
> 
> Could you specify the language version of the generated parser code? This 
> will help in specifying the correct compiler to use for the generated parser 
> source code and headers.

You mean that we should specify that C++ means C++98, C C90, etc.?

We aim to relatively old versions of the various standards.

For Java, the test suite uses Java 1.7, but we might support older versions of 
Java, I actually don't know.

Wrt to D, I have no idea how generations/versions of the language are specified.



Concretely, what problem did you have to fix that would have been solved by 
more documentation?