diff options
author | ringabout <43030857+ringabout@users.noreply.github.com> | 2024-09-03 15:19:52 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-03 09:19:52 +0200 |
commit | 4bf323d6c44b329fe1955f210580a73952c081d0 (patch) | |
tree | 4d699dd2fb98db4916858d58ecb163fa6801381b /compiler/backendpragmas.nim | |
parent | 538603e01d9b0c4abd47799bbe031960ffea3610 (diff) | |
download | Nim-4bf323d6c44b329fe1955f210580a73952c081d0.tar.gz |
fixes push warnings for sempass2 (#23603)
ref https://forum.nim-lang.org/t/11590
Diffstat (limited to 'compiler/backendpragmas.nim')
-rw-r--r-- | compiler/backendpragmas.nim | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/compiler/backendpragmas.nim b/compiler/backendpragmas.nim deleted file mode 100644 index b18644810..000000000 --- a/compiler/backendpragmas.nim +++ /dev/null @@ -1,25 +0,0 @@ -import pragmas, options, ast, trees - -proc pushBackendOption(optionsStack: var seq[TOptions], options: var TOptions) = - optionsStack.add options - -proc popBackendOption(optionsStack: var seq[TOptions], options: var TOptions) = - options = optionsStack[^1] - optionsStack.setLen(optionsStack.len-1) - -proc processPushBackendOption*(optionsStack: var seq[TOptions], options: var TOptions, - n: PNode, start: int) = - pushBackendOption(optionsStack, options) - for i in start..<n.len: - let it = n[i] - if it.kind in nkPragmaCallKinds and it.len == 2 and it[1].kind == nkIntLit: - let sw = whichPragma(it[0]) - let opts = pragmaToOptions(sw) - if opts != {}: - if it[1].intVal != 0: - options.incl opts - else: - options.excl opts - -template processPopBackendOption*(optionsStack: var seq[TOptions], options: var TOptions) = - popBackendOption(optionsStack, options) |