Re: Which C++ language version?

2018-03-26 Thread Peter kovacs
Oha. Learned something new. I will try this!

I think we should work in the direction of the standard guideline that is 
published by Barne Stourstupe. That will lead us to c++11.
I think that will prepare us for the future.

We move slowly anyway.

Am 26. März 2018 08:20:06 MESZ schrieb Don Lewis :
>On 26 Mar, Peter kovacs wrote:
>> I had to build with -std=c++11 on gcc 7.
>> C++98 did not work as far as I remeber.
>> C++17 did lead also to failure I believe.
>> 
>> So I think we use features from the partial support already.
>
>I think we are depending on some GNU extensions to C++98, so our code
>is
>not strictly C++98 compliant.  Try -std=gnu++98.  That's what I
>switched
>to in the FreeBSD port when clang was upgraded and changed its default
>C++ version from C++98 + extensions to C++14.  Some of our code is
>definitely not compliant to C++14 or newer.  Our code compiles with
>-std=gnu++98, and I think that -std=c++0x and -std=c++11 may work as
>well.
>
>Some of the errors with -std=c++14 are easily fixable, but not all.  I
>think there are some places in the code where fixing it for -std=c++14
>would break it for -std=gnu++98.
>
>That doesn't mean that we can use all C++11 features.  We are confined
>to the subset of C++0x implemented by the version of gcc in CentOS 6
>(see https://gcc.gnu.org/gcc-4.4/cxx0x_status.html and read the
>warnings), as well as whatever is is implemented by the version of the
>Windows toolchain that we use.
>
>
>-
>To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
>For additional commands, e-mail: dev-h...@openoffice.apache.org

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org



Re: Which C++ language version?

2018-03-26 Thread Don Lewis
On 26 Mar, Damjan Jovanovic wrote:
> Don't we use C++ 2003?

Good question.  That version is not listed here:
https://gcc.gnu.org/projects/cxx-status.html
Under the C++98 section it does mention that the 2003 modifications are
supported with -std=c++98 and -std=gnu++98.

That version is also not listed in the clang documentation.


-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org



Re: Which C++ language version?

2018-03-26 Thread Don Lewis
On 26 Mar, Peter kovacs wrote:
> I had to build with -std=c++11 on gcc 7.
> C++98 did not work as far as I remeber.
> C++17 did lead also to failure I believe.
> 
> So I think we use features from the partial support already.

I think we are depending on some GNU extensions to C++98, so our code is
not strictly C++98 compliant.  Try -std=gnu++98.  That's what I switched
to in the FreeBSD port when clang was upgraded and changed its default
C++ version from C++98 + extensions to C++14.  Some of our code is
definitely not compliant to C++14 or newer.  Our code compiles with
-std=gnu++98, and I think that -std=c++0x and -std=c++11 may work as
well.

Some of the errors with -std=c++14 are easily fixable, but not all.  I
think there are some places in the code where fixing it for -std=c++14
would break it for -std=gnu++98.

That doesn't mean that we can use all C++11 features.  We are confined
to the subset of C++0x implemented by the version of gcc in CentOS 6
(see https://gcc.gnu.org/gcc-4.4/cxx0x_status.html and read the
warnings), as well as whatever is is implemented by the version of the
Windows toolchain that we use.


-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org



Re: Which C++ language version?

2018-03-25 Thread Damjan Jovanovic
Don't we use C++ 2003?

On Mon, Mar 26, 2018 at 7:41 AM, Peter kovacs  wrote:

> I had to build with -std=c++11 on gcc 7.
> C++98 did not work as far as I remeber.
> C++17 did lead also to failure I believe.
>
> So I think we use features from the partial support already.
>
> Am 26. März 2018 03:03:56 MESZ schrieb Don Lewis :
> >On 25 Mar, Patricia Shanahan wrote:
> >> What version of the C++ standard should we code to?
> >
> >At least for now, C++ 98.  The version of gcc in CentOS 6 only has
> >partial support for C++ 0x.
> >
> >Our Windows build instructions currently recommend a 2007 version of
> >the
> >compiler and libraries, which predate the 2011 standard.
> >
> >> For example, can the move to STL use features that were added in C++
> >11?
> >
> >These may be available via boost.
> >
> >-
> >To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
> >For additional commands, e-mail: dev-h...@openoffice.apache.org
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
> For additional commands, e-mail: dev-h...@openoffice.apache.org
>
>


Re: Which C++ language version?

2018-03-25 Thread Peter kovacs
I had to build with -std=c++11 on gcc 7.
C++98 did not work as far as I remeber.
C++17 did lead also to failure I believe.

So I think we use features from the partial support already.

Am 26. März 2018 03:03:56 MESZ schrieb Don Lewis :
>On 25 Mar, Patricia Shanahan wrote:
>> What version of the C++ standard should we code to?
>
>At least for now, C++ 98.  The version of gcc in CentOS 6 only has
>partial support for C++ 0x.
>
>Our Windows build instructions currently recommend a 2007 version of
>the
>compiler and libraries, which predate the 2011 standard.
> 
>> For example, can the move to STL use features that were added in C++
>11?
>
>These may be available via boost.
>
>-
>To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
>For additional commands, e-mail: dev-h...@openoffice.apache.org

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org



Re: Which C++ language version?

2018-03-25 Thread Don Lewis
On 25 Mar, Patricia Shanahan wrote:
> What version of the C++ standard should we code to?

At least for now, C++ 98.  The version of gcc in CentOS 6 only has
partial support for C++ 0x.

Our Windows build instructions currently recommend a 2007 version of the
compiler and libraries, which predate the 2011 standard.
 
> For example, can the move to STL use features that were added in C++ 11?

These may be available via boost.

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org



Which C++ language version?

2018-03-25 Thread Patricia Shanahan

What version of the C++ standard should we code to?

For example, can the move to STL use features that were added in C++ 11?

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org