[cfe-commits] r160784 - in /cfe/trunk: include/clang/AST/DeclBase.h include/clang/Driver/CC1Options.td include/clang/Frontend/ASTConsumers.h include/clang/Frontend/FrontendOptions.h lib/AST/DeclPrinter.cpp lib/AST/DumpXML.cpp lib/Frontend/ASTConsumers.cpp lib/Frontend/CompilerInvocation.cpp lib/Frontend/FrontendActions.cpp

Jordan Rose jordan_rose at apple.com
Thu Jul 26 09:21:13 PDT 2012


On Jul 26, 2012, at 9:01 , Alexander Kornienko <alexfh at google.com> wrote:

> Author: alexfh
> Date: Thu Jul 26 11:01:23 2012
> New Revision: 160784
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=160784&view=rev
> Log:
> Added -ast-dump-filter option to clang -cc1.
> 
> Modified:
>    cfe/trunk/include/clang/AST/DeclBase.h
>    cfe/trunk/include/clang/Driver/CC1Options.td
>    cfe/trunk/include/clang/Frontend/ASTConsumers.h
>    cfe/trunk/include/clang/Frontend/FrontendOptions.h
>    cfe/trunk/lib/AST/DeclPrinter.cpp
>    cfe/trunk/lib/AST/DumpXML.cpp
>    cfe/trunk/lib/Frontend/ASTConsumers.cpp
>    cfe/trunk/lib/Frontend/CompilerInvocation.cpp
>    cfe/trunk/lib/Frontend/FrontendActions.cpp
> 
> Modified: cfe/trunk/include/clang/AST/DeclBase.h
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/DeclBase.h?rev=160784&r1=160783&r2=160784&view=diff
> ==============================================================================
> --- cfe/trunk/include/clang/AST/DeclBase.h (original)
> +++ cfe/trunk/include/clang/AST/DeclBase.h Thu Jul 26 11:01:23 2012
> @@ -857,9 +857,8 @@
>   static void printGroup(Decl** Begin, unsigned NumDecls,
>                          raw_ostream &Out, const PrintingPolicy &Policy,
>                          unsigned Indentation = 0);
> -  LLVM_ATTRIBUTE_USED void dump() const;
> -  LLVM_ATTRIBUTE_USED void dumpXML() const;
> -  void dumpXML(raw_ostream &OS) const;
> +  LLVM_ATTRIBUTE_USED void dump(raw_ostream &Out = llvm::errs()) const;
> +  LLVM_ATTRIBUTE_USED void dumpXML(raw_ostream &OS = llvm::errs()) const;

The reason why we like having a dump() without a default argument is because debuggers don't usually respect default arguments. Please put it back!



More information about the cfe-commits mailing list