Browse Source

* Make SetLength() to emit hint "Local variable "s" of a managed type does not seem to be initialized" instead of the warning. This change is needed because when calling a regular procedure with a ver parameter of a managed type the hint is generated. Now SetLength() behaves the same.

git-svn-id: trunk@40180 -
yury 6 years ago
parent
commit
1b151df89f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      compiler/ninl.pas

+ 1 - 1
compiler/ninl.pas

@@ -1740,7 +1740,7 @@ implementation
         { last param must be var }
         destppn:=ppn.left;
         valid_for_var(destppn,true);
-        set_varstate(destppn,vs_written,[vsf_must_be_valid]);
+        set_varstate(destppn,vs_written,[vsf_must_be_valid,vsf_use_hints]);
         { first param must be a string or dynamic array ...}
         isarray:=is_dynamic_array(destppn.resultdef);
         if not((destppn.resultdef.typ=stringdef) or