@@ -33,6 +33,7 @@ along with GCC; see the file COPYING3. If not see
#include "dmd/module.h"
#include "dmd/mtype.h"
#include "dmd/target.h"
+#include "dmd/template.h"
#include "opts.h"
#include "alias.h"
@@ -1306,6 +1307,9 @@ d_parse_file (void)
}
}
+ if (global.params.vtemplates)
+ printTemplateStats ();
+
/* Generate JSON files. */
if (global.params.doJsonGeneration)
{
@@ -1891,16 +1891,7 @@ start_function (FuncDeclaration *fd)
modules not in this compilation, or thunk aliases. */
TemplateInstance *ti = fd->isInstantiated ();
if (ti && ti->needsCodegen ())
- {
- /* Warn about templates instantiated in this compilation. */
- if (ti == fd->parent)
- {
- warning (OPT_Wtemplates, "%s %qs instantiated",
- ti->kind (), ti->toPrettyChars (false));
- }
-
- DECL_EXTERNAL (fndecl) = 0;
- }
+ DECL_EXTERNAL (fndecl) = 0;
else
{
Module *md = fd->getModule ();
@@ -138,10 +138,6 @@ Wspeculative
D
Warn from speculative compiles such as __traits(compiles).
-Wtemplates
-D
-; Documented in C
-
Wunknown-pragmas
D Var(warn_unknown_pragmas) LangEnabledBy(D, Wextra)
; Documented in C