introspection: use (nullable) or (optional) instead of (allow-none)

If we have an input parameter (or return value) we need to use (nullable).
However, if it is an (inout) or (out) parameter, (optional) is sufficient.

It looks like (nullable) could be used for everything according to the
Annotation documentation, but (optional) is more specific.
This commit is contained in:
Christian Hergert
2016-10-28 18:29:02 -07:00
parent a4012abbdf
commit 18a33f72db
151 changed files with 986 additions and 987 deletions

View File

@@ -139,7 +139,7 @@ g_socket_connection_is_connected (GSocketConnection *connection)
* g_socket_connection_connect:
* @connection: a #GSocketConnection
* @address: a #GSocketAddress specifying the remote address.
* @cancellable: (allow-none): a %GCancellable or %NULL
* @cancellable: (nullable): a %GCancellable or %NULL
* @error: #GError for error reporting, or %NULL to ignore.
*
* Connect @connection to the specified remote address.
@@ -169,7 +169,7 @@ static gboolean g_socket_connection_connect_callback (GSocket *socket,
* g_socket_connection_connect_async:
* @connection: a #GSocketConnection
* @address: a #GSocketAddress specifying the remote address.
* @cancellable: (allow-none): a %GCancellable or %NULL
* @cancellable: (nullable): a %GCancellable or %NULL
* @callback: (scope async): a #GAsyncReadyCallback
* @user_data: (closure): user data for the callback
*