|
From: Martin W. <mai...@ma...> - 2016-03-10 19:28:52
|
Thanks Orson. It is indeed a problem with older versons of gcc. Before pushing your patch, I'd like
to ask if the other developers think it is worth pandering to this. The issue arises when you have
something like:
class c {
public:
void set_i(int i);
int i();
...
}
Older versions of GCC (< 5.0) complain that the local variable 'i' in 'set_i' shadows the function
'i'. Newer versions permit it.
There are a couple of remaining warnings of this nature in vvp (not of Orson's making).
Martin
P.S. When I run the test suite, the vhdl_multidim_array test is failing. Is this expected?
Maciej Sumiński wrote:
> Thank you Martin. I do not get these warnings with gcc 5.3.0, it seems
> that only older versions care about the problem. Please see the attached
> patch.
>
> Regards,
> Orson
>
> On 03/08/2016 09:56 PM, Martin Whitaker wrote:
>> This pull has also introduced a number of shadow warnings, e.g.
>>
>> g++ -I. -I.. -I../../source/vhdlpp -I../../source/vhdlpp/.. -I../../source/vhdlpp/../libmisc
>> -DHAVE_CONFIG_H -Wall -Wextra -Wshadow -g -O2 -MD -c ../../source/vhdlpp/main.cc -o main.o
>> In file included from ../../source/vhdlpp/std_funcs.h:23:0,
>> from ../../source/vhdlpp/main.cc:79:
>> ../../source/vhdlpp/subprogram.h: In constructor
>> 'SubprogramStdHeader::SubprogramStdHeader(perm_string, std::list<InterfacePort*>*, const VType*)':
>> ../../source/vhdlpp/subprogram.h:150:40: warning: declaration of 'name' shadows a member of 'this'
>> [-Wshadow]
>> const VType*return_type) :
>>
>>
>> ------------------------------------------------------------------------------
>> Transform Data into Opportunity.
>> Accelerate data analysis in your applications with
>> Intel Data Analytics Acceleration Library.
>> Click to learn more.
>> http://makebettercode.com/inteldaal-eval
>> _______________________________________________
>> Iverilog-devel mailing list
>> Ive...@li...
>> https://lists.sourceforge.net/lists/listinfo/iverilog-devel
>>
>
>
>
> ------------------------------------------------------------------------------
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
>
>
>
> _______________________________________________
> Iverilog-devel mailing list
> Ive...@li...
> https://lists.sourceforge.net/lists/listinfo/iverilog-devel
>
|