[cfe-commits] r91543 - in /cfe/trunk: include/clang/Basic/LangOptions.h include/clang/Driver/CC1Options.td include/clang/Driver/Options.td lib/Driver/Tools.cpp lib/Frontend/CompilerInvocation.cpp lib/Sema/Sema.h lib/Sema/SemaDecl.cpp lib/Sema/SemaExprCXX.cpp test/CodeGenCXX/new.cpp test/CodeGenCXX/operator-new.cpp test/CodeGenCXX/static-init.cpp

Chris Lattner clattner at apple.com
Thu Dec 17 11:02:58 PST 2009


On Dec 16, 2009, at 8:59 AM, Nuno Lopes wrote:

> Author: nlopes
> Date: Wed Dec 16 10:59:22 2009
> New Revision: 91543
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=91543&view=rev
> Log:
> implement PR5654: add -fassume-sane-operator-new, which is enabled by default, and adds the malloc attribute to the global function new() and to the overloaded new operators.

Thanks Nuno!

> +++ cfe/trunk/include/clang/Driver/CC1Options.td Wed Dec 16 10:59:22 2009
> @@ -304,6 +304,8 @@
>   HelpText<"Enable AltiVec vector initializer syntax">;
> def faccess_control : Flag<"-faccess-control">,
>   HelpText<"Enable C++ access control">;
> +def fno_assume_sane_operator_new : Flag<"-fno-assume-sane-operator-new">,
> +  HelpText<"Don't assume that C++'s new operator is sane">;

For the help description how about something like "Don't assume that C++'s global operator new can't alias any pointer"?

Thanks for tackling this!

-Chris





More information about the cfe-commits mailing list