Skip to content
  1. Feb 27, 2009
  2. Feb 26, 2009
  3. Feb 25, 2009
    • Douglas Gregor's avatar
      Perform additional semantic checking of class template · f47b911f
      Douglas Gregor authored
      specializations. In particular:
      
        - Make sure class template specializations have a "template<>"
          header, and complain if they don't.
        - Make sure class template specializations are declared/defined
          within a valid context. (e.g., you can't declare a specialization
          std::vector<MyType> in the global namespace).
      
      llvm-svn: 65476
      f47b911f
    • Douglas Gregor's avatar
      Implement parsing of nested-name-specifiers that involve template-ids, e.g., · 7f741127
      Douglas Gregor authored
        std::vector<int>::allocator_type
      
      When we parse a template-id that names a type, it will become either a
      template-id annotation (which is a parsed representation of a
      template-id that has not yet been through semantic analysis) or a
      typename annotation (where semantic analysis has resolved the
      template-id to an actual type), depending on the context. We only
      produce a type in contexts where we know that we only need type
      information, e.g., in a type specifier. Otherwise, we create a
      template-id annotation that can later be "upgraded" by transforming it
      into a typename annotation when the parser needs a type. This occurs,
      for example, when we've parsed "std::vector<int>" above and then see
      the '::' after it. However, it means that when writing something like
      this:
      
        template<> class Outer::Inner<int> { ... };
      
      We have two tokens to represent Outer::Inner<int>: one token for the
      nested name specifier Outer::, and one template-id annotation token
      for Inner<int>, which will be passed to semantic analysis to define
      the class template specialization.
      
      Most of the churn in the template tests in this patch come from an
      improvement in our error recovery from ill-formed template-ids.
      
      llvm-svn: 65467
      7f741127
    • Douglas Gregor's avatar
      C99 DR #316 implies that the function parameter types that are known · 739ef0c1
      Douglas Gregor authored
      only from a function definition (that does not have a prototype) are
      only used to determine the compatible with other declarations of that
      same function. In particular, when referencing the function we pretend
      as if it does not have a prototype. Implement this behavior, which
      fixes PR3626.
      
      llvm-svn: 65460
      739ef0c1
  4. Feb 24, 2009
  5. Feb 23, 2009
  6. Feb 22, 2009
  7. Feb 21, 2009
  8. Feb 20, 2009
Loading