From: Douglas Gregor Date: Sat, 1 May 2010 16:59:21 +0000 (+0000) Subject: Bump default template instantiation depth to 1024, as required by C++0x X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e2e69ef80ac09a489d00ce104e2e87867dc3dd26;p=clang Bump default template instantiation depth to 1024, as required by C++0x git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102847 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/LangOptions.h b/include/clang/Basic/LangOptions.h index f88b0ef325..1ed86f190a 100644 --- a/include/clang/Basic/LangOptions.h +++ b/include/clang/Basic/LangOptions.h @@ -162,7 +162,7 @@ public: OverflowChecking = 0; ObjCGCBitmapPrint = 0; - InstantiationDepth = 500; + InstantiationDepth = 1024; Optimize = 0; OptimizeSize = 0; diff --git a/lib/Frontend/CompilerInvocation.cpp b/lib/Frontend/CompilerInvocation.cpp index 932c35e4f4..8ffdde2aa9 100644 --- a/lib/Frontend/CompilerInvocation.cpp +++ b/lib/Frontend/CompilerInvocation.cpp @@ -1236,7 +1236,7 @@ static void ParseLangArgs(LangOptions &Opts, ArgList &Args, Opts.AccessControl = !Args.hasArg(OPT_fno_access_control); Opts.ElideConstructors = !Args.hasArg(OPT_fno_elide_constructors); Opts.MathErrno = Args.hasArg(OPT_fmath_errno); - Opts.InstantiationDepth = getLastArgIntValue(Args, OPT_ftemplate_depth, 99, + Opts.InstantiationDepth = getLastArgIntValue(Args, OPT_ftemplate_depth, 1024, Diags); Opts.NeXTRuntime = !Args.hasArg(OPT_fgnu_runtime); Opts.ObjCConstantStringClass = getLastArgValue(Args,