Re: Patch 8.0.1723

2018-04-19 Fir de Conversatie John Marriott


On 19-Apr.-2018 06:58, Bram Moolenaar wrote:

Yeah, at least the configure check works.  But clearly this change will
mean you can no longer compile Vim.  So let's not allow for flexible
array members.  It's a nice feature, pity we can't use it.

I'll make a patch to revert this, please check that it works again.


Hi Bram,

Yes it's a shame and I'm sorry about that.

After patch 8.0.1735 HP-UX is happy again, thanks.

If/when our upgrade happens I will let you know.

Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_dev" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-18 Fir de Conversatie Bram Moolenaar

John Marriott wrote:

> On 18-Apr.-2018 07:24, Bram Moolenaar wrote:
> > John Marriott wrote:
> >
> >> On 17-Apr.-2018 00:38, Mike Williams wrote:
> >>> Hi
> >>>
> >>> On 16/04/2018 14:16, Bram Moolenaar wrote:
>  I wrote:
> 
> > Patch 8.0.1723
> > Problem:    Using one item array size declaration is misleading.
> > Solution:   Instead of using "[1]" and actually using a larger
> > array, use
> >              "[]".  This is to verify that this C99 
> > feature works
> > for all
> >              compilers.
> > Files:      src/structs.h, src/getchar.c
>  If you notice a prolem because of this patch, please speak up!
>  Also if it's just a compiler warning.  We want to know if this C99
>  feature works for everybody.
> >> After this patch (8.0.1723), HP-UX throws this error:
> >> 
> >> Starting make in the src directory.
> >> If there are problems, cd to the src directory and run make there
> >>     cd src && make first
> >>     cc -c -I. -Iproto -DHAVE_CONFIG_H   -O2  -o objects/arabic.o 
> >> arabic.c
> >> cc: "structs.h", line 514: error 1578: Size of struct or union member is
> >> unknown.
> >> *** Error exit code 1
> >>
> >> Stop.
> >> *** Error exit code 1
> >>
> >> Stop.
> >> 
> >>
> >> It looks like HP-UX compiler doesn't like flexible arrays.
> > Disappointing...
> >
> > This document suggests it was added at some point:
> > https://support.hpe.com/hpsc/doc/public/display?docId=emr_na-c02670372
> >
> > Apparently it was added with version B.11.11.16.
> > What version are you using?
> > Is there any way to upgrade?
> >
> According to "uname -a" I am on:
> HP-UX B.11.11 U 9000/800
> The c compiler says it is:
> HP C/HP-UX Version 11.11.02
> 
> Old stuff I know. The machine *might* be retired and replaced with a Red 
> Hat linux box in the next 18 months or so. Maybe. In the meantime, there 
> is no chance of an upgrade.
> 
> Also, after the related patch 8.0.1730, the HP-UX throws this (from 
> configure):
> 
> Starting make in the src directory.
> If there are problems, cd to the src directory and run make there
>     cd src && make first
>     rm -f auto/config.cache
> ...
> checking for nawk... no
> checking for awk... awk
> checking for strip... strip
> checking for ANSI C header files... yes
> checking for sys/wait.h that is POSIX.1 compatible... yes
> checking if the compiler can handle Vim code... configure: error: 
> compiler does not work properly - see auto/config.log
> *** Error exit code 1
> 
> Stop.
> *** Error exit code 1
> 
> Stop.

Yeah, at least the configure check works.  But clearly this change will
mean you can no longer compile Vim.  So let's not allow for flexible
array members.  It's a nice feature, pity we can't use it.

I'll make a patch to revert this, please check that it works again.

-- 
hundred-and-one symptoms of being an internet addict:
220. Your wife asks for sex and you tell her where to find you on IRC.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-18 Fir de Conversatie John Marriott

On 18-Apr.-2018 07:24, Bram Moolenaar wrote:

John Marriott wrote:


On 17-Apr.-2018 00:38, Mike Williams wrote:

Hi

On 16/04/2018 14:16, Bram Moolenaar wrote:

I wrote:


Patch 8.0.1723
Problem:    Using one item array size declaration is misleading.
Solution:   Instead of using "[1]" and actually using a larger
array, use
             "[]".  This is to verify that this C99 feature works
for all
             compilers.
Files:      src/structs.h, src/getchar.c

If you notice a prolem because of this patch, please speak up!
Also if it's just a compiler warning.  We want to know if this C99
feature works for everybody.

After this patch (8.0.1723), HP-UX throws this error:

Starting make in the src directory.
If there are problems, cd to the src directory and run make there
    cd src && make first
    cc -c -I. -Iproto -DHAVE_CONFIG_H   -O2  -o objects/arabic.o arabic.c
cc: "structs.h", line 514: error 1578: Size of struct or union member is
unknown.
*** Error exit code 1

Stop.
*** Error exit code 1

Stop.


It looks like HP-UX compiler doesn't like flexible arrays.

Disappointing...

This document suggests it was added at some point:
https://support.hpe.com/hpsc/doc/public/display?docId=emr_na-c02670372

Apparently it was added with version B.11.11.16.
What version are you using?
Is there any way to upgrade?


According to "uname -a" I am on:
HP-UX B.11.11 U 9000/800
The c compiler says it is:
HP C/HP-UX Version 11.11.02

Old stuff I know. The machine *might* be retired and replaced with a Red 
Hat linux box in the next 18 months or so. Maybe. In the meantime, there 
is no chance of an upgrade.


Also, after the related patch 8.0.1730, the HP-UX throws this (from 
configure):


Starting make in the src directory.
If there are problems, cd to the src directory and run make there
   cd src && make first
   rm -f auto/config.cache
...
checking for nawk... no
checking for awk... awk
checking for strip... strip
checking for ANSI C header files... yes
checking for sys/wait.h that is POSIX.1 compatible... yes
checking if the compiler can handle Vim code... configure: error: 
compiler does not work properly - see auto/config.log

*** Error exit code 1

Stop.
*** Error exit code 1

Stop.


Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_dev" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-17 Fir de Conversatie Bram Moolenaar

John Marriott wrote:

> On 17-Apr.-2018 00:38, Mike Williams wrote:
> > Hi
> >
> > On 16/04/2018 14:16, Bram Moolenaar wrote:
> >>
> >> I wrote:
> >>
> >>> Patch 8.0.1723
> >>> Problem:    Using one item array size declaration is misleading.
> >>> Solution:   Instead of using "[1]" and actually using a larger 
> >>> array, use
> >>>  "[]".  This is to verify that this C99 feature works 
> >>> for all
> >>>  compilers.
> >>> Files:  src/structs.h, src/getchar.c
> >>
> >> If you notice a prolem because of this patch, please speak up!
> >> Also if it's just a compiler warning.  We want to know if this C99
> >> feature works for everybody.
> >
> After this patch (8.0.1723), HP-UX throws this error:
> 
> Starting make in the src directory.
> If there are problems, cd to the src directory and run make there
>    cd src && make first
>    cc -c -I. -Iproto -DHAVE_CONFIG_H   -O2  -o objects/arabic.o arabic.c
> cc: "structs.h", line 514: error 1578: Size of struct or union member is 
> unknown.
> *** Error exit code 1
> 
> Stop.
> *** Error exit code 1
> 
> Stop.
> 
> 
> It looks like HP-UX compiler doesn't like flexible arrays.

Disappointing...

This document suggests it was added at some point:
https://support.hpe.com/hpsc/doc/public/display?docId=emr_na-c02670372

Apparently it was added with version B.11.11.16.
What version are you using?
Is there any way to upgrade?

-- 
hundred-and-one symptoms of being an internet addict:
211. Your husband leaves you...taking the computer with him and you
 call him crying, and beg him to bring the computer back.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-17 Fir de Conversatie Cesar Romani

On 16/04/2018 08:16 a.m., Bram Moolenaar wrote:
>
> [...]
> If you notice a problem because of this patch, please speak up!
> Also if it's just a compiler warning.  We want to know if this C99
> feature works for everybody.

I'm using mingw-w64 on Windows 7, gcc 7.2.0, and I don't get any
warnings related to the C99 feature, but I get these warnings:


undo.c: In function 'u_save_cursor':
undo.c:270:6: warning: assuming signed overflow does not occur when 
assuming that (X - c) > X is always false [-Wstrict-overflow]

 if (top > curbuf->b_ml.ml_line_count
 
  || top >= bot
  ^

[...]
userfunc.c: In function 'get_funccal_local_ht':
userfunc.c:3594:2: warning: assuming signed overflow does not occur when 
assuming that (X + c) < X is always false [-Wstrict-overflow]

  for (i = 0; i < debug_backtrace_level; i++)
  ^~~
userfunc.c: In function 'get_funccal_local_var':
userfunc.c:3594:2: warning: assuming signed overflow does not occur when 
assuming that (X + c) < X is always false [-Wstrict-overflow]

  for (i = 0; i < debug_backtrace_level; i++)
  ^~~
userfunc.c: In function 'get_funccal_args_ht':
userfunc.c:3594:2: warning: assuming signed overflow does not occur when 
assuming that (X + c) < X is always false [-Wstrict-overflow]

  for (i = 0; i < debug_backtrace_level; i++)
  ^~~
userfunc.c: In function 'get_funccal_args_var':
userfunc.c:3594:2: warning: assuming signed overflow does not occur when 
assuming that (X + c) < X is always false [-Wstrict-overflow]

  for (i = 0; i < debug_backtrace_level; i++)

[...]
gui_dwrite.cpp: In member function 'HRESULT 
DWriteContext::SetDrawingMode(DrawingMode)':
gui_dwrite.cpp:950:10: warning: comparison between signed and unsigned 
integer expressions [-Wsign-compare]

   if (hr == D2DERR_RECREATE_TARGET)


--
Cesar

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_dev" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-17 Fir de Conversatie John Marriott


On 17-Apr.-2018 00:38, Mike Williams wrote:

Hi

On 16/04/2018 14:16, Bram Moolenaar wrote:


I wrote:


Patch 8.0.1723
Problem:    Using one item array size declaration is misleading.
Solution:   Instead of using "[1]" and actually using a larger 
array, use
 "[]".  This is to verify that this C99 feature works 
for all

 compilers.
Files:  src/structs.h, src/getchar.c


If you notice a prolem because of this patch, please speak up!
Also if it's just a compiler warning.  We want to know if this C99
feature works for everybody.



After this patch (8.0.1723), HP-UX throws this error:

Starting make in the src directory.
If there are problems, cd to the src directory and run make there
  cd src && make first
  cc -c -I. -Iproto -DHAVE_CONFIG_H   -O2  -o objects/arabic.o arabic.c
cc: "structs.h", line 514: error 1578: Size of struct or union member is 
unknown.

*** Error exit code 1

Stop.
*** Error exit code 1

Stop.


It looks like HP-UX compiler doesn't like flexible arrays.
Cheers
John

--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_dev" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-16 Fir de Conversatie Mike Williams

Hi

On 16/04/2018 14:16, Bram Moolenaar wrote:


I wrote:


Patch 8.0.1723
Problem:Using one item array size declaration is misleading.
Solution:   Instead of using "[1]" and actually using a larger array, use
 "[]".  This is to verify that this C99 feature works for all
 compilers.
Files:  src/structs.h, src/getchar.c


If you notice a prolem because of this patch, please speak up!
Also if it's just a compiler warning.  We want to know if this C99
feature works for everybody.


The use of unsized arrays as the last member of a structure is supported 
as an extension in MSVC, at least as far back as VS2008.  There are 
other extensions but finding a list is not trivial.  There is the /Za 
compiler option to disable the extensions, but this throws up a whole 
new bunch of compiler messages to due extensive use of the extensions in 
the system include files making spotting issues in vim code a needle in 
the haystack problem.


TTFN

Mike
--
A diplomat is a man who always remembers a woman's birthday but never 
remembers her age.


--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_dev" group.

To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-16 Fir de Conversatie Tony Mechelynck
FWIW I don't see any compiler messages (neither in Huge nor in Tiny)
but I'm on Linux and it's MSVC support which is problematic. Let's see
if we get errors or warnings on Windows.

Best regards,
Tony.

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Patch 8.0.1723

2018-04-16 Fir de Conversatie Bram Moolenaar

I wrote:

> Patch 8.0.1723
> Problem:Using one item array size declaration is misleading.
> Solution:   Instead of using "[1]" and actually using a larger array, use
> "[]".  This is to verify that this C99 feature works for all
> compilers.
> Files:  src/structs.h, src/getchar.c

If you notice a prolem because of this patch, please speak up!
Also if it's just a compiler warning.  We want to know if this C99
feature works for everybody.

-- 
Press any key to continue, press any other key to quit.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.