mirror of
https://github.com/logos-storage/logos-storage-nim-validator.git
synced 2026-01-03 14:03:07 +00:00
10 lines
293 B
Nim
10 lines
293 B
Nim
import ../basics
|
|
|
|
type NetworkAddress* = distinct TransportAddress
|
|
|
|
func init*(_: type NetworkAddress, address: string): ?!NetworkAddress =
|
|
NetworkAddress(initTAddress(address)).catch()
|
|
|
|
func `==`*(a, b: NetworkAddress): bool {.borrow.}
|
|
func `$`*(address: NetworkAddress): string {.borrow.}
|