diff options
author | Araq <rumpf_a@web.de> | 2013-02-21 15:05:11 -0800 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2013-02-21 15:05:11 -0800 |
commit | dad664ca714ee681d22fb93344388fde2c9ff472 (patch) | |
tree | a08304713bf4703895f3dfe22a89fd08f16521ec /lib/system.nim | |
parent | 45c9975e9c9fe063d68aa5eb6df0457ca9ac7457 (diff) | |
parent | 7168ceb5e1ec6686b13f5da1f2c9a4db07ac90ec (diff) | |
download | Nim-dad664ca714ee681d22fb93344388fde2c9ff472.tar.gz |
Merge pull request #341 from Tass/master
Basic logic for objects
Diffstat (limited to 'lib/system.nim')
-rwxr-xr-x | lib/system.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/system.nim b/lib/system.nim index 5f9a24ba9..db78d2740 100755 --- a/lib/system.nim +++ b/lib/system.nim @@ -1532,7 +1532,7 @@ iterator fieldPairs*[S: tuple|object, T: tuple|object](x: S, y: T): tuple[ ## The current implementation also has a bug that affects symbol binding ## in the loop body. -proc `==`*[T: tuple](x, y: T): bool = +proc `==`*[T: tuple|object](x, y: T): bool = ## generic ``==`` operator for tuples that is lifted from the components ## of `x` and `y`. for a, b in fields(x, y): @@ -1557,7 +1557,7 @@ proc `<`*[T: tuple](x, y: T): bool = if c > 0: return false return false -proc `$`*[T: tuple](x: T): string = +proc `$`*[T: tuple|object](x: T): string = ## generic ``$`` operator for tuples that is lifted from the components ## of `x`. Example: ## |