Merge remote-tracking branch 'origin/topic/vern/cpp-prep-fixes'

* origin/topic/vern/cpp-prep-fixes:
  fix for associating current scope with the name of enums; name tidying
  avoid infinite recursion in same_type() if it is analyzing recursive types
  remove iffy reliance on type punning that relies on interpreter's behavior
  fixes for propagating optimization options, and pruning script function analysis
This commit is contained in:
Tim Wojtulewicz 2021-03-18 12:45:04 -07:00
commit 4f24c02cd5
8 changed files with 228 additions and 53 deletions

View file

@ -127,13 +127,9 @@ function format_value(value: any) : string
if ( /^set/ in tn && strstr(tn, ",") == 0 )
{
# The conversion to set here is tricky and assumes
# that the set isn't indexed via a tuple of types.
# The above check for commas in the type name
# ensures this.
local it: set[bool] = value;
for ( sv in it )
part += cat(sv);
local vec = Option::any_set_to_any_vec(value);
for ( sv in vec )
part += cat(vec[sv]);
return join_string_vec(part, ",");
}
else if ( /^vector/ in tn )