tests: Trim .nim files trailing whitespace

via OSX: find . -name '*.nim' -exec sed -i '' -E 's/[[:space:]]+$//' {} +
This commit is contained in:
Adam Strzelecki 2015-09-04 23:04:32 +02:00
commit e80465dacf
372 changed files with 4486 additions and 4486 deletions

View file

@ -7,11 +7,11 @@ type
TObj = object {.pure, inheritable.}
TObjB = object of TObj
a, b, c: string
IO2Error = ref object of IOError
proc forw: int {. .}
proc lier(): int {.raises: [IO2Error].} =
writeLine stdout, "arg"

View file

@ -7,9 +7,9 @@ type
TObj = object {.pure, inheritable.}
TObjB = object of TObj
a, b, c: string
EIO2 = ref object of IOError
proc forw: int {.raises: [].}
proc lier(): int {.raises: [IOError].} =

View file

@ -8,9 +8,9 @@ type
TObjB = object of TObj
a, b, c: string
fn: proc (): int {.tags: [].}
EIO2 = ref object of EIO
proc raiser(): int {.tags: [TObj, FWriteIO].} =
writeLine stdout, "arg"

View file

@ -8,12 +8,12 @@ type
TObjB = object of TObj
a, b, c: string
fn: proc (): int {.tags: [FReadIO].}
EIO2 = ref object of EIO
proc q() {.tags: [FIO].} =
nil
proc raiser(): int =
writeLine stdout, "arg"
if true:

View file

@ -6,7 +6,7 @@ discard """
proc p(q: proc() ): proc() {.tags: [], raises: [], closure.} =
return proc () =
q()
let yay = p(proc () = raise newException(EIO, "IO"))
proc main() {.raises: [], tags: [].} = yay()

View file

@ -3,7 +3,7 @@ type
PMenu = ref object
PMenuItem = ref object
proc createMenuItem*(menu: PMenu, label: string,
proc createMenuItem*(menu: PMenu, label: string,
action: proc (i: PMenuItem, p: pointer) {.cdecl.}) = discard
var s: PMenu
@ -19,7 +19,7 @@ createMenuItem(s, "Go to definition...",
proc noRaise(x: proc()) {.raises: [].} =
# unknown call that might raise anything, but valid:
x()
proc doRaise() {.raises: [EIO].} =
raise newException(EIO, "IO")

View file

@ -11,8 +11,8 @@ proc dontcare(x: int): int = return x + global
proc SideEffectLyer(x, y: int): int {.noSideEffect.} = #ERROR_MSG 'SideEffectLyer' can have side effects
return x + y + dontcare(x)
echo SideEffectLyer(1, 3)
echo SideEffectLyer(1, 3)

View file

@ -8,9 +8,9 @@ var
proc dontcare(x: int): int = return x
proc SideEffectLyer(x, y: int): int {.noSideEffect.} =
proc SideEffectLyer(x, y: int): int {.noSideEffect.} =
return x + y + dontcare(x)
echo SideEffectLyer(1, 3) #OUT 5

View file

@ -8,9 +8,9 @@ var
proc dontcare(x: int): int {.noSideEffect.} = return x
proc noSideEffect(x, y: int, p: proc (a: int): int {.noSideEffect.}): int {.noSideEffect.} =
proc noSideEffect(x, y: int, p: proc (a: int): int {.noSideEffect.}): int {.noSideEffect.} =
return x + y + dontcare(x)
echo noSideEffect(1, 3, dontcare) #OUT 5

View file

@ -9,9 +9,9 @@ var
proc dontcare(x: int): int = return x
proc noSideEffect(x, y: int, p: proc (a: int): int {.noSideEffect.}): int {.noSideEffect.} =
proc noSideEffect(x, y: int, p: proc (a: int): int {.noSideEffect.}): int {.noSideEffect.} =
return x + y + dontcare(x)
echo noSideEffect(1, 3, dontcare) #ERROR_MSG type mismatch