* treat all "uninitialized" hints as warnings on JVM platforms, because

they generally result in fatal run time errors there

git-svn-id: trunk@22571 -
This commit is contained in:
Jonas Maebe 2012-10-07 09:10:08 +00:00
parent f8288d1b53
commit 76b0ee9925

View File

@ -1190,14 +1190,20 @@ implementation
begin
if tloadnode(p).symtable.symtabletype=localsymtable then
begin
if (vsf_use_hints in varstateflags) then
{ on the JVM, an uninitialized var-parameter
is just as fatal as a nil pointer dereference }
if (vsf_use_hints in varstateflags) and
not(target_info.system in systems_jvm) then
CGMessagePos1(p.fileinfo,sym_h_uninitialized_local_variable,hsym.realname)
else
CGMessagePos1(p.fileinfo,sym_w_uninitialized_local_variable,hsym.realname);
end
else
begin
if (vsf_use_hints in varstateflags) then
{ on the JVM, an uninitialized var-parameter
is just as fatal as a nil pointer dereference }
if (vsf_use_hints in varstateflags) and
not(target_info.system in systems_jvm) then
CGMessagePos1(p.fileinfo,sym_h_uninitialized_variable,hsym.realname)
else
CGMessagePos1(p.fileinfo,sym_w_uninitialized_variable,hsym.realname);