Changeset 5c9b20c


Ignore:
Timestamp:
Jun 4, 2020, 3:50:57 PM (4 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
52a4d69, 73973b6
Parents:
bcd74f3
Message:

Fixed void ptr assignment bug

Location:
src/AST
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Copy.hpp

    rbcd74f3 r5c9b20c  
    1313// Update Count     : 0
    1414//
     15
     16#pragma once
    1517
    1618#include "Decl.hpp"
  • src/AST/TypeSubstitution.hpp

    rbcd74f3 r5c9b20c  
    153153// PassVisitor are defined before PassVisitor implementation accesses TypeSubstitution internals.
    154154#include "Pass.hpp"
     155#include "Copy.hpp"
    155156
    156157namespace ast {
     
    184185        assert( input );
    185186        Pass<Substituter> sub( *this, false );
    186         input = strict_dynamic_cast< const SynTreeClass * >( input->accept( sub ) );
     187        input = strict_dynamic_cast< const SynTreeClass * >( deepCopy(input)->accept( sub ) );
    187188        return { input, sub.pass.subCount };
    188189}
Note: See TracChangeset for help on using the changeset viewer.