fix breakage with Nim HEAD

This commit is contained in:
Ștefan Talpalaru 2019-01-03 22:22:24 +01:00 committed by zah
parent b21e381dfa
commit 7c185b1731
2 changed files with 1 additions and 3 deletions

View File

@ -235,8 +235,6 @@ proc receive(d: DiscoveryProtocol, a: Address, msg: Bytes) =
d.recvNeighbours(node, payload) d.recvNeighbours(node, payload)
of cmdFindNode: of cmdFindNode:
d.recvFindNode(node, payload) d.recvFindNode(node, payload)
else:
debug "Unknown command", cmdId
else: else:
trace "Received msg already expired", cmdId, a trace "Received msg already expired", cmdId, a
else: else:

View File

@ -86,7 +86,7 @@ proc removePeer(network: LesNetwork, peer: LesPeer) =
network.delistFromFlowControl peer network.delistFromFlowControl peer
network.peers.excl peer network.peers.excl peer
template costQuantity(quantityExpr: int, max: int) {.pragma.} template costQuantity(quantityExpr, max: untyped) {.pragma.}
proc getCostQuantity(fn: NimNode): tuple[quantityExpr, maxQuantity: NimNode] = proc getCostQuantity(fn: NimNode): tuple[quantityExpr, maxQuantity: NimNode] =
# XXX: `getCustomPragmaVal` doesn't work yet on regular nnkProcDef nodes # XXX: `getCustomPragmaVal` doesn't work yet on regular nnkProcDef nodes