Changeset 30ee9ef


Ignore:
Timestamp:
Nov 2, 2018, 7:44:59 AM (3 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
aaron-thesis, arm-eh, cleanup-dtors, deferred_resn, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer
Children:
f855545
Parents:
76beed8
Message:

print error for indexed access to struct fields

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/ResolvExpr/AlternativeFinder.cc

    r76beed8 r30ee9ef  
    1010// Created On       : Sat May 16 23:52:08 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Feb 17 11:19:39 2018
    13 // Update Count     : 33
     12// Last Modified On : Thu Nov  1 21:00:56 2018
     13// Update Count     : 34
    1414//
    1515
     
    13441344                /// Gets name from untyped member expression (member must be NameExpr)
    13451345                const std::string& get_member_name( UntypedMemberExpr *memberExpr ) {
     1346                        if ( dynamic_cast< ConstantExpr * >( memberExpr->get_member() ) ) {
     1347                                SemanticError( memberExpr, "Indexed access to struct fields unsupported: " );
     1348                        } // if
    13461349                        NameExpr * nameExpr = dynamic_cast< NameExpr * >( memberExpr->get_member() );
    13471350                        assert( nameExpr );
Note: See TracChangeset for help on using the changeset viewer.