Ignore:
Timestamp:
May 19, 2015, 4:58:14 PM (9 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
Children:
843054c2
Parents:
01aeade
Message:

licencing: sixth groups of files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • translator/Designators/Processor.h

    r01aeade ra08ba92  
    55// file "LICENCE" distributed with Cforall.
    66//
    7 // XXX.cc --
     7// Processor.h --
    88//
    99// Author           : Richard C. Bilson
    1010// Created On       : Mon May 18 07:44:20 2015
    11 // Last Modified By :
    12 // Last Modified On :
    13 // Update Count     : 0
     11// Last Modified By : Peter A. Buhr
     12// Last Modified On : Tue May 19 16:24:34 2015
     13// Update Count     : 3
    1414//
     15
    1516#include "SynTree/Declaration.h"
    1617#include "SynTree/Expression.h"
     
    2425
    2526namespace Designators {
    26   class Matcher;
    27   class GenSym;
     27        class Matcher;
     28        class GenSym;
    2829
    29   template < class OutputIterator >  bool extractNames( std::list< DeclarationWithType * > &, OutputIterator );
    30   template < class OutputIterator >  bool extractNames( Expression *, OutputIterator, Matcher );
    31   void check_alternative( FunctionType *, ResolvExpr::AltList & );
    32   ObjectDecl *extractTupleV( Matcher, TupleExpr *names );
    33   bool fixDesignations( ResolvExpr::AlternativeFinder &finder, Expression *designation );
    34   DeclarationWithType *gensym( GenSym &, DeclarationWithType * );
     30        template < class OutputIterator >  bool extractNames( std::list< DeclarationWithType * > &, OutputIterator );
     31        template < class OutputIterator >  bool extractNames( Expression *, OutputIterator, Matcher );
     32        void check_alternative( FunctionType *, ResolvExpr::AltList & );
     33        ObjectDecl *extractTupleV( Matcher, TupleExpr *names );
     34        bool fixDesignations( ResolvExpr::AlternativeFinder &finder, Expression *designation );
     35        DeclarationWithType *gensym( GenSym &, DeclarationWithType * );
    3536
    36   class GenSym {
    37   public:
    38     GenSym( std::string prefix = "" ) : gensym_count(0) {}
    39     GenSym( GenSym &other ) { gensym_count = other.gensym_count; }
     37        class GenSym {
     38          public:
     39                GenSym( std::string prefix = "" ) : gensym_count(0) {}
     40                GenSym( GenSym &other ) { gensym_count = other.gensym_count; }
    4041
    4142//    std::string get_symbol() { }
    42   private:
    43     std::string prefix;
    44     int gensym_count;
    45   };
     43          private:
     44                std::string prefix;
     45                int gensym_count;
     46        };
    4647
    47   // template< typename Key >
    48   class Matcher {
    49   public:
    50     typedef std::vector< std::string >::iterator iterator;
     48        // template< typename Key >
     49        class Matcher {
     50          public:
     51                typedef std::vector< std::string >::iterator iterator;
    5152
    52     Matcher( const std::list< DeclarationWithType * > & );
    53     ~Matcher() {}
     53                Matcher( const std::list< DeclarationWithType * > & );
     54                ~Matcher() {}
    5455
    55     template< class OutputIterator > bool get_reorderedCall( OutputIterator );
    56     template< class InputIterator >  bool add(InputIterator, InputIterator, ResolvExpr::Alternative &);
    57     template< class InputIterator, class OutputIterator >  bool slice(InputIterator begin, InputIterator end, OutputIterator );
    58     //std::vector<std::string> &get_order() const { return order; }
     56                template< class OutputIterator > bool get_reorderedCall( OutputIterator );
     57                template< class InputIterator >  bool add(InputIterator, InputIterator, ResolvExpr::Alternative &);
     58                template< class InputIterator, class OutputIterator >  bool slice(InputIterator begin, InputIterator end, OutputIterator );
     59                //std::vector<std::string> &get_order() const { return order; }
    5960
    60     iterator begin() { return order.begin(); }
    61     iterator end() { return order.end(); }
     61                iterator begin() { return order.begin(); }
     62                iterator end() { return order.end(); }
    6263
    63     //Expression *operator[]( int idx ) { return table( order[ idx ] ); }
    64   private:
    65     std::map< std::string, int > table;
    66     std::vector<std::string> order;
    67     std::vector<DeclarationWithType *> declarations;
    68     std::vector<ResolvExpr::Alternative *> alternatives;
    69   };
    70   //  void pruneAlternatives( Expression *expr, ResolvExpr::AlternativeFinder & );
    71 
     64                //Expression *operator[]( int idx ) { return table( order[ idx ] ); }
     65          private:
     66                std::map< std::string, int > table;
     67                std::vector<std::string> order;
     68                std::vector<DeclarationWithType *> declarations;
     69                std::vector<ResolvExpr::Alternative *> alternatives;
     70        };
     71        //  void pruneAlternatives( Expression *expr, ResolvExpr::AlternativeFinder & );
    7272} // namespace Designators
    7373
    74 /*
    75   Local Variables:
    76   mode: c++
    77   End:
    78 */
    7974// Local Variables: //
    8075// tab-width: 4 //
Note: See TracChangeset for help on using the changeset viewer.