Ignore:
Timestamp:
May 2, 2019, 1:57:05 PM (3 years ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
arm-eh, cleanup-dtors, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr
Children:
62ce290
Parents:
3e96559
Message:

Reduced cases where unused is placed on anonymous objects. Regenerated tests.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/CodeGen/CodeGenerator.cc

    r3e96559 r76f7fc7  
    1010// Created On       : Mon May 18 07:44:20 2015
    1111// Last Modified By : Andrew Beach
    12 // Last Modified On : Wed May  1 15:50:00 2019
    13 // Update Count     : 496
     12// Last Modified On : Thr May  2 10:47:00 2019
     13// Update Count     : 497
    1414//
    1515#include "CodeGenerator.h"
     
    182182
    183183                Options subOptions = options;
    184                 subOptions.inParameterList = true;
     184                subOptions.anonymousUnused = functionDecl->has_body();
    185185                output << genType( functionDecl->get_functionType(), mangleName( functionDecl ), subOptions );
    186186
     
    203203                        objectDecl->set_name( name.newName() );
    204204            // Stops unused parameter warnings.
    205             if ( options.inParameterList ) {
     205            if ( options.anonymousUnused ) {
    206206                objectDecl->attributes.push_back( new Attribute( "unused" ) );
    207207            }
Note: See TracChangeset for help on using the changeset viewer.