deprecated ospaths (#9665)
This commit is contained in:
parent
8507e506ce
commit
8d850f7a69
13 changed files with 838 additions and 811 deletions
|
|
@ -85,6 +85,7 @@ proc initDefines*(symbols: StringTableRef) =
|
|||
defineSymbol("nimHasUserErrors")
|
||||
defineSymbol("nimUncheckedArrayTyp")
|
||||
defineSymbol("nimHasTypeof")
|
||||
defineSymbol("nimErrorProcCanHaveBody")
|
||||
|
||||
defineSymbol("nimHasNilSeqs")
|
||||
for f in low(Feature)..high(Feature):
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
|
||||
import
|
||||
intsets, ast, idents, algorithm, renderer, parser, ospaths, strutils,
|
||||
intsets, ast, idents, algorithm, renderer, parser, os, strutils,
|
||||
sequtils, msgs, modulegraphs, syntaxes, options, modulepaths, tables,
|
||||
lineinfos
|
||||
|
||||
|
|
|
|||
|
|
@ -1670,7 +1670,7 @@ proc semProcAux(c: PContext, n: PNode, kind: TSymKind,
|
|||
localError(c.config, n.info, "the overloaded " & s.name.s &
|
||||
" operator has to be enabled with {.experimental: \"callOperator\".}")
|
||||
|
||||
if n.sons[bodyPos].kind != nkEmpty:
|
||||
if n.sons[bodyPos].kind != nkEmpty and sfError notin s.flags:
|
||||
# for DLL generation it is annoying to check for sfImportc!
|
||||
if sfBorrow in s.flags:
|
||||
localError(c.config, n.sons[bodyPos].info, errImplOfXNotAllowed % s.name.s)
|
||||
|
|
|
|||
|
|
@ -112,9 +112,9 @@ proc registerAdditionalOps*(c: PCtx) =
|
|||
registerCallback(c, "stdlib.math.mod", `mod Wrapper`)
|
||||
|
||||
when defined(nimcore):
|
||||
wrap2s(getEnv, ospathsop)
|
||||
wrap1s(existsEnv, ospathsop)
|
||||
wrap2svoid(putEnv, ospathsop)
|
||||
wrap2s(getEnv, osop)
|
||||
wrap1s(existsEnv, osop)
|
||||
wrap2svoid(putEnv, osop)
|
||||
wrap1s(dirExists, osop)
|
||||
wrap1s(fileExists, osop)
|
||||
wrap2svoid(writeFile, systemop)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue