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
parent ac9c1cd6b9
commit e80465dacf
372 changed files with 4486 additions and 4486 deletions

View File

@@ -5,10 +5,10 @@ type
a: int
TB = object of TA
b: array[0..5000_000, int]
proc ap(x: var TA) = x.a = -1
proc bp(x: var TB) = x.b[high(x.b)] = -1
# in Nim proc (x: TB) is compatible to proc (x: TA),
# but this is not type safe:
var f = cast[proc (x: var TA) {.nimcall.}](bp)

View File

@@ -3,7 +3,7 @@ import unittest
type Obj = object
foo: int
proc makeObj(x: int): Obj =
proc makeObj(x: int): Obj =
result.foo = x
suite "object basic methods":

View File

@@ -4,7 +4,7 @@
type
TFoo = ref object of RootObj
Data: int
Data: int
TBar = ref object of TFoo
nil
TBar2 = ref object of TBar

View File

@@ -18,7 +18,7 @@ type
of 0: arg: char
of 1: s: string
else: wtf: bool
var
x: TMyObject

View File

@@ -12,7 +12,7 @@ discard """
# Disabled since some versions of GCC ignore the 'packed' attribute
# Test
# Test
type
Foo {.packed.} = object
@@ -21,12 +21,12 @@ type
Bar {.packed.} = object
a: int8
b: int16
b: int16
Daz {.packed.} = object
a: int32
b: int8
c: int32
b: int8
c: int32
var f = Foo(a: 1, b: 1)

View File

@@ -8,12 +8,12 @@ type
TMyType = object {.inheritable.}
len: int
data: string
TOtherType = object of TMyType
proc p(x: TMyType): bool =
proc p(x: TMyType): bool =
return x of TOtherType
var
m: TMyType
n: TOtherType

View File

@@ -5,13 +5,13 @@ discard """
type
TA = object of TObject
x, y: int
TB = object of TA
z: int
TC = object of TB
whatever: string
proc p(a: var TA) = echo "a"
proc p(b: var TB) = echo "b"