From 0fc4c99eb1266e00a7901f23b74a384f9c4fe59f Mon Sep 17 00:00:00 2001 From: Slava Pestov <slava@slava-pestovs-macbook-pro.local> Date: Thu, 15 May 2008 20:07:01 -0500 Subject: [PATCH] help.lint fixes --- extra/cocoa/application/application-docs.factor | 4 ++-- extra/io/sockets/sockets-docs.factor | 2 +- extra/io/sockets/sockets.factor | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/extra/cocoa/application/application-docs.factor b/extra/cocoa/application/application-docs.factor index 01a79cf35a..55fa5e10b8 100644 --- a/extra/cocoa/application/application-docs.factor +++ b/extra/cocoa/application/application-docs.factor @@ -27,8 +27,8 @@ HELP: with-cocoa { $description "Sets up an autorelease pool, initializes the " { $snippet "NSApplication" } " singleton, and calls the quotation." } ; HELP: do-event -{ $values { "app" "an " { $snippet "NSApplication" } } } -{ $description "Processes any pending events in the queue. Does not block." } ; +{ $values { "app" "an " { $snippet "NSApplication" } } { "?" "a boolean" } } +{ $description "Processes a pending event in the queue, if any, returning a boolean indicating if there was one. Does not block." } ; HELP: add-observer { $values { "observer" "an " { $snippet "NSObject" } } { "selector" string } { "name" "an " { $snippet "NSString" } } { "object" "an " { $snippet "NSObject" } } } diff --git a/extra/io/sockets/sockets-docs.factor b/extra/io/sockets/sockets-docs.factor index 7ef08575c0..668312e3f1 100755 --- a/extra/io/sockets/sockets-docs.factor +++ b/extra/io/sockets/sockets-docs.factor @@ -130,7 +130,7 @@ HELP: <server> { $errors "Throws an error if the address is already in use, or if it if the system forbids access." } ; HELP: accept -{ $values { "server" "a handle" } { "client" "a bidirectional stream" } { "addrspec" "an address specifier" } } +{ $values { "server" "a handle" } { "client" "a bidirectional stream" } { "remote" "an address specifier" } } { $description "Waits for a connection to a server socket created by " { $link <server> } ", and outputs a bidirectional stream when the connection has been established. The encoding of this stream is the one that was passed to the server constructor." } { $errors "Throws an error if the server socket is closed or otherwise is unavailable." } ; diff --git a/extra/io/sockets/sockets.factor b/extra/io/sockets/sockets.factor index da10354261..031343351e 100755 --- a/extra/io/sockets/sockets.factor +++ b/extra/io/sockets/sockets.factor @@ -185,7 +185,7 @@ M: object (client) ( remote -- client-in client-out local ) SYMBOL: local-address -: with-client ( addrspec encoding quot -- ) +: with-client ( remote encoding quot -- ) >r <client> [ local-address set ] curry r> compose with-stream ; inline @@ -217,7 +217,7 @@ TUPLE: datagram-port < port addr ; HOOK: (datagram) io-backend ( addr -- datagram ) -: <datagram> ( addr -- datagram ) +: <datagram> ( addrspec -- datagram ) dup (datagram) datagram-port <port> swap >>addr ; : check-datagram-port ( port -- port ) @@ -226,7 +226,7 @@ HOOK: (datagram) io-backend ( addr -- datagram ) HOOK: (receive) io-backend ( datagram -- packet addrspec ) -: receive ( datagram -- packet sockaddr ) +: receive ( datagram -- packet addrspec ) check-datagram-port [ (receive) ] [ addr>> ] bi parse-sockaddr ;