// // Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo // // The contents of this file are covered under the licence agreement in the // file "LICENCE" distributed with Cforall. // // GenInit.cc -- // // Author : Rob Schluntz // Created On : Mon May 18 07:44:20 2015 // Last Modified By : Peter A. Buhr // Last Modified On : Fri Mar 17 09:12:36 2017 // Update Count : 183 // #include "GenInit.h" #include // for NULL #include // for any_of #include // for assert, strict_dynamic_cast, assertf #include // for back_inserter, inserter, back_inse... #include // for _List_iterator, list #include "CodeGen/OperatorTable.h" #include "Common/PassVisitor.h" // for PassVisitor, WithGuards, WithShort... #include "Common/SemanticError.h" // for SemanticError #include "Common/UniqueName.h" // for UniqueName #include "Common/utility.h" // for ValueGuard, maybeClone #include "GenPoly/DeclMutator.h" // for DeclMutator #include "GenPoly/GenPoly.h" // for getFunctionType, isPolyType #include "GenPoly/ScopedSet.h" // for ScopedSet, ScopedSet<>::const_iter... #include "InitTweak.h" // for isConstExpr, InitExpander, checkIn... #include "Parser/LinkageSpec.h" // for isOverridable, C #include "SymTab/Autogen.h" // for genImplicitCall, SizeType #include "SymTab/Mangler.h" // for Mangler #include "SynTree/Declaration.h" // for ObjectDecl, DeclarationWithType #include "SynTree/Expression.h" // for VariableExpr, UntypedExpr, Address... #include "SynTree/Initializer.h" // for ConstructorInit, SingleInit, Initi... #include "SynTree/Label.h" // for Label #include "SynTree/Mutator.h" // for mutateAll #include "SynTree/Statement.h" // for CompoundStmt, ImplicitCtorDtorStmt #include "SynTree/Type.h" // for Type, ArrayType, Type::Qualifiers #include "SynTree/Visitor.h" // for acceptAll, maybeAccept namespace InitTweak { namespace { const std::list