Skip to content

Commit a6fd572

Browse files
committed
some UI cleanups
1 parent 87d0342 commit a6fd572

File tree

3 files changed

+12
-14
lines changed

3 files changed

+12
-14
lines changed

R/aio.R

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,10 @@
3636
#' (invisibly) instead of NULL. The data may then be extracted from the Aio
3737
#' using \code{$result}, \code{$raw} or \code{$data} as the case may be.
3838
#'
39-
#' It is not advisable to try to extract the data from a 'recvAio' in one
40-
#' step using something like \code{call_aio(x)$data} in the non-blocking case.
39+
#' It is not advisable to use, for example, \code{call_aio(x, block = FALSE)$data}.
4140
#' This is as \code{call_aio()} will return NULL if the Aio is unresolved and
4241
#' \code{NULL$data} is also \code{NULL}, hence it would be impossible to
43-
#' distinguish between an unresolved Aio and a NULL return value.
42+
#' distinguish between an unresolved Aio and a NULL return value in this case.
4443
#'
4544
#' @examples
4645
#' s1 <- socket("pair", listen = "inproc://nanonext")

R/listdial.R

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,14 +82,14 @@ dial <- function(socket,
8282
res <- .Call(rnng_dial, .subset2(socket, "socket"), url)
8383
if (is.integer(res)) {
8484
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
85-
return(res)
85+
return(invisible(res))
8686
}
8787
if (!missing(quietly) && !isTRUE(quietly)) cat(format.POSIXct(Sys.time()), "[ dialer start ]", url)
8888
} else {
8989
res <- .Call(rnng_dialer_create, .subset2(socket, "socket"), url)
9090
if (is.integer(res)) {
9191
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
92-
return(res)
92+
return(invisible(res))
9393
}
9494
}
9595
socket[["dialer"]] <- c(.subset2(socket, "dialer"), res)
@@ -108,14 +108,14 @@ dial <- function(socket,
108108
res <- .Call(rnng_dial, socket, url)
109109
if (is.integer(res)) {
110110
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
111-
return(res)
111+
return(invisible(res))
112112
}
113113
if (!missing(quietly) && !isTRUE(quietly)) cat(format.POSIXct(Sys.time()), "[ dialer start ]", url)
114114
} else {
115115
res <- .Call(rnng_dialer_create, socket, url)
116116
if (is.integer(res)) {
117117
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
118-
return(res)
118+
return(invisible(res))
119119
}
120120
}
121121
attr(socket, "dialer") <- c(attr(socket, "dialer"), res)
@@ -206,14 +206,14 @@ listen <- function(socket,
206206
res <- .Call(rnng_listen, .subset2(socket, "socket"), url)
207207
if (is.integer(res)) {
208208
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
209-
return(res)
209+
return(invisible(res))
210210
}
211211
if (!missing(quietly) && !isTRUE(quietly)) cat(format.POSIXct(Sys.time()), "[ listener start ]", url)
212212
} else {
213213
res <- .Call(rnng_listener_create, .subset2(socket, "socket"), url)
214214
if (is.integer(res)) {
215215
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
216-
return(res)
216+
return(invisible(res))
217217
}
218218
}
219219
socket[["listener"]] <- c(.subset2(socket, "listener"), res)
@@ -232,14 +232,14 @@ listen <- function(socket,
232232
res <- .Call(rnng_listen, socket, url)
233233
if (is.integer(res)) {
234234
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
235-
return(res)
235+
return(invisible(res))
236236
}
237237
if (!missing(quietly) && !isTRUE(quietly)) cat(format.POSIXct(Sys.time()), "[ listener start ]", url)
238238
} else {
239239
res <- .Call(rnng_listener_create, socket, url)
240240
if (is.integer(res)) {
241241
message(Sys.time(), " [ ", res, " ] ", nng_error(res))
242-
return(res)
242+
return(invisible(res))
243243
}
244244
}
245245
attr(socket, "listener") <- c(attr(socket, "listener"), res)

man/call_aio.Rd

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)