Skip to content
  1. Oct 17, 2007
  2. Oct 15, 2007
    • Steve Naroff's avatar
      · 32e44c00
      Steve Naroff authored
      Move type compatibility predicates from Type to ASTContext. In addition, the predicates are now instance methods (they were previously static class methods on Type).
      
      This allowed me to fix the following hack from this weekend...
      
      // FIXME: Devise a way to do this without using strcmp.
      // Would like to say..."return getAsStructureType() == IdStructType;", but
      // we don't have a pointer to ASTContext.
      bool Type::isObjcIdType() const {
        if (const RecordType *RT = getAsStructureType())
          return !strcmp(RT->getDecl()->getName(), "objc_object");
        return false;
      }
      
      ...which is now...
      
      bool isObjcIdType(QualType T) const {
        return T->getAsStructureType() == IdStructType;
      }
      
      Side notes:
      
      - I had to remove a convenience function from the TypesCompatibleExpr class.
      
      int typesAreCompatible() const {return Type::typesAreCompatible(Type1,Type2);}
      
      Which required a couple clients get a little more verbose...
      
      -    Result = TCE->typesAreCompatible();
      +    Result = Ctx.typesAreCompatible(TCE->getArgType1(), TCE->getArgType2());
      
      Overall, I think this change also makes sense for a couple reasons...
      
      1) Since ASTContext vends types, it makes sense for the type compatibility API to be there.
      2) This allows the type compatibility predeciates to refer to data not strictly present in the AST (which I have found problematic on several occasions).
      
      llvm-svn: 43009
      32e44c00
    • Anders Carlsson's avatar
      Add code generation and sema checking for __builtin_va_arg. · 7e13ab88
      Anders Carlsson authored
      llvm-svn: 43006
      7e13ab88
  3. Oct 13, 2007
  4. Oct 09, 2007
  5. Oct 08, 2007
  6. Oct 07, 2007
  7. Oct 05, 2007
  8. Sep 28, 2007
  9. Sep 22, 2007
  10. Sep 16, 2007
  11. Sep 14, 2007
    • Steve Naroff's avatar
      · a23cc796
      Steve Naroff authored
      Move Decl::NextDeclarator (w/ setters/getters) down to ScopedDecl/FieldDecl.
      
      Decl is now svelte:-)
      
      llvm-svn: 41935
      a23cc796
  12. Sep 13, 2007
  13. Sep 07, 2007
    • Hartmut Kaiser's avatar
      Fixed compilation on Windows. · ec7531c9
      Hartmut Kaiser authored
      Silenced a couple of warnings.
      Added *.vcproj file for new clangAnalysis library.
      Renamed Basic to clangBasic projects.
      
      llvm-svn: 41767
      ec7531c9
  14. Sep 04, 2007
  15. Sep 01, 2007
  16. Aug 31, 2007
  17. Aug 30, 2007
    • Steve Naroff's avatar
      · 5c13180a
      Steve Naroff authored
      Fix the following redefinition errors submitted by Keith Bauer...
      
      [dylan:~/llvm/tools/clang] admin% cat tentative_decls.c 
      // incorrectly generates redefinition error
      extern int array[3];
      int array[3];
      
      // incorrectly generates a redefinition error
      extern void nup(int a[3]);
      void nup(int a[3]) {}
      
      It turns out that this exposed a fairly major flaw in the type system,
      array types were never getting uniqued! This is because all array types
      contained an expression, which aren't unique.
      
      To solve this, we now have 2 array types, ConstantArrayType and
      VariableArrayType. ConstantArrayType's are unique, VAT's aren't.
      
      This is a fairly extensive set of fundamental changes. Fortunately,
      all the tests pass. Nevertheless, there may be some collateral damage:-)
      If so, let me know!
      
      llvm-svn: 41592
      5c13180a
  18. Aug 29, 2007
  19. Aug 28, 2007
  20. Aug 27, 2007
Loading