Ignore:
Timestamp:
Sep 14, 2022, 9:46:19 AM (21 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, ast-experimental, master, pthread-emulation
Children:
1c0657a
Parents:
fc96890
Message:

Translated Instantiate Generic to the new AST. This includes various utilities and some assorted clean-up.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/ScrubTyVars.h

    rfc96890 r3606fe4  
    99// Author           : Richard C. Bilson
    1010// Created On       : Mon May 18 07:44:20 2015
    11 // Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Jul 22 09:21:47 2017
    13 // Update Count     : 2
     11// Last Modified By : Andrew Beach
     12// Last Modified On : Fri Aug 19 14:14:00 2022
     13// Update Count     : 3
    1414//
    1515
     
    1818#include <cassert>            // for assert
    1919
     20#include "AST/Fwd.hpp"        // for Node
    2021#include "Common/PassVisitor.h"
    2122#include "GenPoly.h"          // for TyVarMap, isPolyType, isDynType
     
    108109        }
    109110
     111/// For all polymorphic types, replaces generic types, with the appropriate
     112/// void type, and sizeof/alignof expressions with the proper variable.
     113template<typename node_t>
     114node_t const * scrubAllTypeVars( node_t const * target ) {
     115        return strict_dynamic_cast<node_t const *>( scrubAllTypeVars<ast::Node>( target ) );
     116}
     117
     118template<>
     119ast::Node const * scrubAllTypeVars<ast::Node>( const ast::Node * target );
     120
    110121} // namespace GenPoly
    111122
Note: See TracChangeset for help on using the changeset viewer.