Changeset c4c8571 for src/SymTab
- Timestamp:
- Jul 28, 2022, 12:04:25 PM (3 years ago)
- Branches:
- ADT, ast-experimental, master, pthread-emulation
- Children:
- 32d1383, d0fcc82
- Parents:
- 3f95dab (diff), 2af1943 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
-
src/SymTab/Autogen.cc (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
src/SymTab/Autogen.cc
r3f95dab rc4c8571 258 258 } 259 259 260 /// 260 /// Given type T, generate type of default ctor/dtor, i.e. function type void (*) (T &). 261 261 ast::FunctionDecl * genDefaultFunc(const CodeLocation loc, const std::string fname, const ast::Type * paramType, bool maybePolymorphic) { 262 262 std::vector<ast::ptr<ast::TypeDecl>> typeParams; 263 263 if (maybePolymorphic) typeParams = getGenericParams(paramType); 264 264 auto dstParam = new ast::ObjectDecl(loc, "_dst", new ast::ReferenceType(paramType), nullptr, {}, ast::Linkage::Cforall); 265 return new ast::FunctionDecl(loc, fname, std::move(typeParams), {dstParam}, {}, new ast::CompoundStmt(loc) );265 return new ast::FunctionDecl(loc, fname, std::move(typeParams), {dstParam}, {}, new ast::CompoundStmt(loc), {}, ast::Linkage::Cforall); 266 266 } 267 267
Note:
See TracChangeset
for help on using the changeset viewer.