diff --git a/changelog.md b/changelog.md index 77a757b1d..b960f5213 100644 --- a/changelog.md +++ b/changelog.md @@ -11,6 +11,7 @@ ## Compiler changes - Specific warnings can now be turned into errors via `--warningAsError[X]:on|off`. +- The `define` and `undef` pragmas have been de-deprecated. ## Tool changes diff --git a/compiler/pragmas.nim b/compiler/pragmas.nim index 674673443..4504d1cc5 100644 --- a/compiler/pragmas.nim +++ b/compiler/pragmas.nim @@ -470,14 +470,12 @@ proc processPop(c: PContext, n: PNode) = proc processDefine(c: PContext, n: PNode) = if (n.kind in nkPragmaCallKinds and n.len == 2) and (n[1].kind == nkIdent): defineSymbol(c.config.symbols, n[1].ident.s) - message(c.config, n.info, warnDeprecated, "define is deprecated") else: invalidPragma(c, n) proc processUndef(c: PContext, n: PNode) = if (n.kind in nkPragmaCallKinds and n.len == 2) and (n[1].kind == nkIdent): undefSymbol(c.config.symbols, n[1].ident.s) - message(c.config, n.info, warnDeprecated, "undef is deprecated") else: invalidPragma(c, n)