Skip to content
  1. Jun 07, 2009
  2. Jun 05, 2009
    • Douglas Gregor's avatar
      Several improvements to template argument deduction: · b7ae10f7
      Douglas Gregor authored
        - Once we have deduced template arguments for a class template partial
          specialization, we use exactly those template arguments for instantiating
          the definition of the class template partial specialization.
        - Added template argument deduction for non-type template parameters.
        - Added template argument deduction for dependently-sized array types.
      
      With these changes, we can now implement, e.g., the remove_reference
      type trait. Also, Daniel's Ackermann template metaprogram now compiles
      properly.
      
      llvm-svn: 72909
      b7ae10f7
  3. May 30, 2009
  4. May 29, 2009
  5. May 27, 2009
    • Douglas Gregor's avatar
      Simplify, and improve the performance of, template instantiation for · cd3a0979
      Douglas Gregor authored
      declaration references. The key realization is that dependent Decls,
      which actually require instantiation, can only refer to the current
      instantiation or members thereof. And, since the current context
      during instantiation contains all of those members of the current
      instantiation, we can simply find the real instantiate that matches up
      with the "current instantiation" template.
      
      llvm-svn: 72486
      cd3a0979
    • Douglas Gregor's avatar
      Improve name lookup for and template instantiation of declaration · f98d9b60
      Douglas Gregor authored
      references. There are several smallish fixes here:
      
        - Make sure we look through template parameter scope when
          determining whether we're parsing a nested class (or nested class
          *template*). This makes sure that we delay parsing the bodies of
          inline member functions until after we're out of the outermost
          class (template) scope.
        - Since the bodies of member functions are always parsed
          "out-of-line", even when they were declared in-line, teach
          unqualified name lookup to look into the (semantic) parents.
        - Use the new InstantiateDeclRef to handle the instantiation of a
          reference to a declaration (in DeclRefExpr), which drastically
          simplifies template instantiation for DeclRefExprs.
        - When we're instantiating a ParmVarDecl, it must be in the current
          instantiation scope, so only look there.
      
      Also, remove the #if 0's and FIXME's from the dynarray example, which
      now compiles and executes thanks to Anders and Eli.
      
      llvm-svn: 72481
      f98d9b60
    • Douglas Gregor's avatar
      Initial stab at a generalized operation for determining the · 51783313
      Douglas Gregor authored
      instantiation of a declaration from the template version (or version
      that lives in a template) and a given set of template arguments. This
      needs much, much more testing, but it suffices for simple examples
      like
      
        typedef T* iterator;
        iterator begin();
      
      llvm-svn: 72461
      51783313
    • Douglas Gregor's avatar
      408c619a
  6. May 23, 2009
  7. May 22, 2009
  8. May 21, 2009
  9. May 20, 2009
  10. May 19, 2009
Loading