diff options
-rw-r--r-- | compiler/commands.nim | 2 | ||||
-rw-r--r-- | compiler/options.nim | 1 | ||||
-rw-r--r-- | compiler/semcall.nim | 7 | ||||
-rw-r--r-- | compiler/semexprs.nim | 5 | ||||
-rw-r--r-- | doc/advopt.txt | 3 |
5 files changed, 3 insertions, 15 deletions
diff --git a/compiler/commands.nim b/compiler/commands.nim index 1b42a191e..22e4b5a2c 100644 --- a/compiler/commands.nim +++ b/compiler/commands.nim @@ -478,8 +478,6 @@ proc processSwitch(switch, arg: string, pass: TCmdLinePass, info: TLineInfo; of "linedir": processOnOffSwitch({optLineDir}, arg, pass, info) of "assertions", "a": processOnOffSwitch({optAssert}, arg, pass, info) of "deadcodeelim": processOnOffSwitchG({optDeadCodeElim}, arg, pass, info) - of "reportconceptfailures": - processOnOffSwitchG({optReportConceptFailures}, arg, pass, info) of "threads": processOnOffSwitchG({optThreads}, arg, pass, info) #if optThreads in gGlobalOptions: incl(gNotes, warnGcUnsafe) diff --git a/compiler/options.nim b/compiler/options.nim index 6372cddac..063dff826 100644 --- a/compiler/options.nim +++ b/compiler/options.nim @@ -41,7 +41,6 @@ type # please make sure we have under 32 options TGlobalOption* = enum # **keep binary compatible** gloptNone, optForceFullMake, optDeadCodeElim, optListCmd, optCompileOnly, optNoLinking, - optReportConceptFailures, # report 'compiles' or 'concept' matching failures optCDebug, # turn on debugging information optGenDynLib, # generate a dynamic library optGenStaticLib, # generate a static library diff --git a/compiler/semcall.nim b/compiler/semcall.nim index ffa940291..b440d1e75 100644 --- a/compiler/semcall.nim +++ b/compiler/semcall.nim @@ -118,7 +118,7 @@ proc notFoundError*(c: PContext, n: PNode, errors: CandidateErrors) = # Gives a detailed error message; this is separated from semOverloadedCall, # as semOverlodedCall is already pretty slow (and we need this information # only in case of an error). - if c.compilesContextId > 0 and optReportConceptFailures notin gGlobalOptions: + if c.compilesContextId > 0: # fail fast: globalError(n.info, errTypeMismatch, "") if errors.isNil or errors.len == 0: @@ -163,10 +163,7 @@ proc notFoundError*(c: PContext, n: PNode, errors: CandidateErrors) = add(candidates, "for a 'var' type a variable needs to be passed, but '" & renderTree(n[mut]) & "' is immutable\n") if candidates != "": add(result, "\n" & msgKindToString(errButExpected) & "\n" & candidates) - if c.compilesContextId > 0 and optReportConceptFailures in gGlobalOptions: - globalError(n.info, errGenerated, result) - else: - localError(n.info, errGenerated, result) + localError(n.info, errGenerated, result) proc bracketNotFoundError(c: PContext; n: PNode) = var errors: CandidateErrors = @[] diff --git a/compiler/semexprs.nim b/compiler/semexprs.nim index 74c4ae5d5..475f496f1 100644 --- a/compiler/semexprs.nim +++ b/compiler/semexprs.nim @@ -1755,8 +1755,7 @@ proc tryExpr(c: PContext, n: PNode, flags: TExprFlags = {}): PNode = result = semExpr(c, n, flags) if msgs.gErrorCounter != oldErrorCount: result = nil except ERecoverableError: - if optReportConceptFailures in gGlobalOptions: - err = getCurrentExceptionMsg() + discard # undo symbol table changes (as far as it's possible): c.compilesContextId = oldCompilesId c.generics = oldGenerics @@ -1770,8 +1769,6 @@ proc tryExpr(c: PContext, n: PNode, flags: TExprFlags = {}): PNode = errorOutputs = oldErrorOutputs msgs.gErrorCounter = oldErrorCount msgs.gErrorMax = oldErrorMax - if optReportConceptFailures in gGlobalOptions and not err.isNil: - localError(n.info, err) proc semCompiles(c: PContext, n: PNode, flags: TExprFlags): PNode = # we replace this node by a 'true' or 'false' node: diff --git a/doc/advopt.txt b/doc/advopt.txt index 991f06397..9a9dab7e0 100644 --- a/doc/advopt.txt +++ b/doc/advopt.txt @@ -54,9 +54,6 @@ Advanced options: --embedsrc embeds the original source code as comments in the generated output --threadanalysis:on|off turn thread analysis on|off - --reportConceptFailures:on|off - show errors for 'system.compiles' and concept - evaluation --tlsEmulation:on|off turn thread local storage emulation on|off --taintMode:on|off turn taint mode on|off --implicitStatic:on|off turn implicit compile time evaluation on|off |