Ignore:
Timestamp:
Oct 3, 2022, 1:46:49 PM (23 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, ast-experimental, master
Children:
890f67a
Parents:
c02cef1
Message:

Make unset locations earier to find with a search for 'CodeLocation?()'.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/InitTweak/InitTweak.cc

    rc02cef1 r4b8b2a4  
    881881                static ast::ptr<ast::FunctionDecl> assign = nullptr;
    882882                if (!assign) {
    883                         auto td = new ast::TypeDecl({}, "T", {}, nullptr, ast::TypeDecl::Dtype, true);
    884                         assign = new ast::FunctionDecl({}, "?=?", {},
    885                         { new ast::ObjectDecl({}, "_dst", new ast::ReferenceType(new ast::TypeInstType("T", td))),
    886                           new ast::ObjectDecl({}, "_src", new ast::TypeInstType("T", td))},
    887                         { new ast::ObjectDecl({}, "_ret", new ast::TypeInstType("T", td))}, nullptr, {}, ast::Linkage::Intrinsic);
     883                        auto td = new ast::TypeDecl(CodeLocation(), "T", {}, nullptr, ast::TypeDecl::Dtype, true);
     884                        assign = new ast::FunctionDecl(CodeLocation(), "?=?", {},
     885                        { new ast::ObjectDecl(CodeLocation(), "_dst", new ast::ReferenceType(new ast::TypeInstType("T", td))),
     886                          new ast::ObjectDecl(CodeLocation(), "_src", new ast::TypeInstType("T", td))},
     887                        { new ast::ObjectDecl(CodeLocation(), "_ret", new ast::TypeInstType("T", td))}, nullptr, {}, ast::Linkage::Intrinsic);
    888888                }
    889889                if (dst->result.as<ast::ReferenceType>()) {
Note: See TracChangeset for help on using the changeset viewer.