MCPcopy Create free account
hub / github.com/csmith-project/csmith / no_loop_initializer

Method no_loop_initializer

src/ArrayVariable.cpp:447–454  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

445}
446
447bool
448ArrayVariable::no_loop_initializer(void) const
449{
450 // don't use loop initializer if we are doing test case reduction
451 // if (CGOptions::get_reducer()) return true;
452 // can not use loop initializer if either array member are structs, or they are constants, or it has > 1 initial values
453 return type->eType==eStruct || type->eType==eUnion || is_const() || is_global() || (init_values.size() > 0);
454}
455
456// print the initializer recursively for multi-dimension arrays
457// this is based on John's idea

Callers 2

output_varsMethod · 0.80
OutputArrayInitializersFunction · 0.80

Calls 1

sizeMethod · 0.80

Tested by

no test coverage detected