Skip to content
  1. Oct 05, 2010
  2. Sep 05, 2010
  3. Jul 01, 2010
  4. Jun 23, 2010
  5. Jun 09, 2010
    • Douglas Gregor's avatar
      Tweak our handling of the notion of a standard conversion sequence · 1fc3d66d
      Douglas Gregor authored
      being a subsequence of another standard conversion sequence. Instead
      of requiring exact type equality for the second conversion step,
      require type *similarity*, which is type equality with cv-qualifiers
      removed at all levels. This appears to match the behavior of EDG and
      VC++ (albeit not GCC), and feels more intuitive. Big thanks to John
      for the line of reasoning that supports this change: since
      cv-qualifiers are orthogonal to the second conversion step, we should
      ignore them in the type comparison.
      
      llvm-svn: 105678
      1fc3d66d
  6. May 25, 2010
  7. May 24, 2010
  8. Apr 24, 2010
    • Douglas Gregor's avatar
      When we are performing copy initialization of a class type via its · c779e995
      Douglas Gregor authored
      copy constructor, suppress user-defined conversions on the
      argument. Otherwise, we can end up in a recursion loop where the
      bind the argument of the copy constructor to another copy constructor call,
      whose argument is then a copy constructor call...
      
      Found by Boost.Regex which, alas, still isn't building.
      
      llvm-svn: 102269
      c779e995
  9. Apr 22, 2010
    • Douglas Gregor's avatar
      Whenever we complain about a failed initialization of a function or · 4f4946aa
      Douglas Gregor authored
      method parameter, provide a note pointing at the parameter itself so
      the user does not have to manually look for the function/method being
      called and match up parameters to arguments. For example, we now get:
      
      t.c:4:5: warning: incompatible pointer types passing 'long *' to
      parameter of
            type 'int *' [-pedantic]
        f(long_ptr);
          ^~~~~~~~
      t.c:1:13: note: passing argument to parameter 'x' here
      void f(int *x);
                  ^
      
      llvm-svn: 102038
      4f4946aa
  10. Apr 18, 2010
  11. Apr 13, 2010
  12. Mar 08, 2010
  13. Feb 28, 2010
  14. Feb 25, 2010
  15. Jan 27, 2010
    • Douglas Gregor's avatar
      Fix a major oversight in the comparison of standard conversion · 3edc4d5e
      Douglas Gregor authored
      sequences, where we would occasionally determine (incorrectly) that
      one standard conversion sequence was a proper subset of another when,
      in fact, they contained completely incomparable conversions. 
      
      This change records the types in each step within a standard
      conversion sequence, so that we can check the specific comparison
      types to determine when one sequence is a proper subset of the
      other. Fixes this testcase (thanks, Anders!), which was distilled from
      PR6095 (also thanks to Anders).
      
      llvm-svn: 94660
      3edc4d5e
  16. Jan 23, 2010
    • John McCall's avatar
      Produce a special diagnostic when users call a function with an argument of · 6d174646
      John McCall authored
      incomplete type (or a pointer/reference to such).
      
      The causes of this problem are different enough to justify a different "design"
      for the diagnostic.  Most notably, it doesn't give an operand index:
      it's usually pretty obvious which operand is the problem, it adds a lot of
      clutter to mention it, and the fix is usually in a different part of the file
      anyway.
      
      This is yet another diagnostic that should really have an analogue in the
      non-overloaded case --- which should be much easier to write because of
      the weaker space constraints.
      
      llvm-svn: 94303
      6d174646
  17. Jan 14, 2010
  18. Jan 13, 2010
  19. Jan 12, 2010
  20. Dec 15, 2009
  21. Dec 13, 2009
  22. Dec 09, 2009
  23. Nov 06, 2009
  24. Mar 24, 2009
  25. Dec 12, 2008
  26. Nov 27, 2008
  27. Oct 29, 2008
    • Douglas Gregor's avatar
      Simplify and correct the check for function redefinitions. This does two things: · cad304ba
      Douglas Gregor authored
        - Allows definitions of overloaded functions :)
        - Eliminates extraneous error messages when we have a definition of a 
          function that isn't an overload but doesn't have exactly the same type
          as the original.
        
      
      llvm-svn: 58382
      cad304ba
    • Douglas Gregor's avatar
      Implement overloading rules for reference binding · ef30a5ff
      Douglas Gregor authored
      llvm-svn: 58381
      ef30a5ff
    • Douglas Gregor's avatar
      Tweak Sema::CheckReferenceInit so that it (optionally) computes an · 786ab211
      Douglas Gregor authored
      ImplicitConversionSequence and, when doing so, following the specific
      rules of [over.best.ics]. 
      
      The computation of the implicit conversion sequences implements C++
      [over.ics.ref], but we do not (yet) have ranking for implicit
      conversion sequences that use reference binding.
      
      llvm-svn: 58357
      786ab211
    • Douglas Gregor's avatar
      Implement initialization of a reference (C++ [dcl.init.ref]) as part · 8e1cf608
      Douglas Gregor authored
      of copy initialization. Other pieces of the puzzle:
      
        - Try/Perform-ImplicitConversion now handles implicit conversions
          that don't involve references.
        - Try/Perform-CopyInitialization uses
          CheckSingleAssignmentConstraints for C. PerformCopyInitialization
          is now used for all argument passing and returning values from a
          function.
        - Diagnose errors with declaring references and const values without
          an initializer. (Uses a new Action callback, ActOnUninitializedDecl).
        
      We do not yet have implicit conversion sequences for reference
      binding, which means that we don't have any overloading support for
      reference parameters yet.
      
      llvm-svn: 58353
      8e1cf608
  28. Oct 23, 2008
    • Douglas Gregor's avatar
      Add support for conversions from a pointer-to-derived to a · 5c407d9a
      Douglas Gregor authored
      pointer-to-base. Also, add overload ranking for pointer conversions
      (for both pointer-to-void and derived-to-base pointer conversions).
      
      Note that we do not yet diagnose derived-to-base pointer conversion
      errors that stem from ambiguous or inacessible base classes. These
      aren't handled during overload resolution; rather, when the conversion
      is actually used we go ahead and diagnose the error.
      
      llvm-svn: 58017
      5c407d9a
  29. Oct 22, 2008
  30. Oct 21, 2008
Loading