From 8013504bbfc59329dc434b07370c6608d0a193ea Mon Sep 17 00:00:00 2001 From: Aaron Weiss Date: Mon, 18 Mar 2024 16:21:31 -0700 Subject: [PATCH] fix links in documentation. --- irc-proto/src/command.rs | 4 ++-- irc-proto/src/message.rs | 2 +- src/client/mod.rs | 12 ++++++------ src/lib.rs | 8 ++++---- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/irc-proto/src/command.rs b/irc-proto/src/command.rs index 65f1629..8f96a8b 100644 --- a/irc-proto/src/command.rs +++ b/irc-proto/src/command.rs @@ -60,7 +60,7 @@ pub enum Command { /// actually mean sending itself a response. In such a case, you should instead respond to the /// user sending the message as specified in the message prefix. Since this is a common /// pattern, there is a utility function - /// [`Message::response_target`](../message/struct.Message.html#method.response_target) + /// [`Message::response_target`] /// which is used for this exact purpose. PRIVMSG(String, String), /// NOTICE msgtarget :message @@ -74,7 +74,7 @@ pub enum Command { /// actually mean sending itself a response. In such a case, you should instead respond to the /// user sending the message as specified in the message prefix. Since this is a common /// pattern, there is a utility function - /// [`Message::response_target`](../message/struct.Message.html#method.response_target) + /// [`Message::response_target`] /// which is used for this exact purpose. NOTICE(String, String), diff --git a/irc-proto/src/message.rs b/irc-proto/src/message.rs index 7b84f93..e44e5cc 100644 --- a/irc-proto/src/message.rs +++ b/irc-proto/src/message.rs @@ -13,7 +13,7 @@ use crate::prefix::Prefix; /// consists of a collection of IRCv3 tags, a prefix (describing the source of the message), and /// the protocol command. If the command is unknown, it is treated as a special raw command that /// consists of a collection of arguments and the special suffix argument. Otherwise, the command -/// is parsed into a more useful form as described in [Command](../command/enum.Command.html). +/// is parsed into a more useful form as described in [`Command`]. #[derive(Clone, PartialEq, Debug)] pub struct Message { /// Message tags as defined by [IRCv3.2](http://ircv3.net/specs/core/message-tags-3.2.html). diff --git a/src/client/mod.rs b/src/client/mod.rs index a8e01d6..0fffaee 100644 --- a/src/client/mod.rs +++ b/src/client/mod.rs @@ -1,8 +1,8 @@ //! A simple, thread-safe, and async-friendly IRC client library. //! //! This API provides the ability to connect to an IRC server via the -//! [`Client`](struct.Client.html) type. The [`Client`](trait.Client.html) trait that -//! [`Client`](struct.Client.html) implements provides methods for communicating with the +//! [`Client`] type. The [`Client`] trait that +//! [`Client`] implements provides methods for communicating with the //! server. //! //! # Examples @@ -22,7 +22,7 @@ //! # } //! ``` //! -//! We can then use functions from [`Client`](trait.Client.html) to receive messages from the +//! We can then use functions from [`Client`] to receive messages from the //! server in a blocking fashion and perform any desired actions in response. The following code //! performs a simple call-and-response when the bot's name is mentioned in a channel. //! @@ -889,7 +889,7 @@ impl Future for Outgoing { /// The canonical implementation of a connection to an IRC server. /// -/// For a full example usage, see [`irc::client`](./index.html). +/// For a full example usage, see [`irc::client`]. #[derive(Debug)] pub struct Client { /// The internal, thread-safe server state. @@ -1015,7 +1015,7 @@ impl Client { None } - /// Gets a list of [`Users`](./data/user/struct.User.html) in the specified channel. If the + /// Gets a list of [`Users`] in the specified channel. If the /// specified channel hasn't been joined or the `channel-lists` feature is disabled, this function /// will return `None`. /// @@ -1052,7 +1052,7 @@ impl Client { self.state.current_nickname() } - /// Sends a [`Command`](../proto/command/enum.Command.html) as this `Client`. This is the + /// Sends a [`Command`] as this `Client`. This is the /// core primitive for sending messages to the server. /// /// # Example diff --git a/src/lib.rs b/src/lib.rs index 6bf9cc3..d6e87a6 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,17 +1,17 @@ //! A simple, thread-safe, and async-friendly library for IRC clients. //! //! # Quick Start -//! The main public API is entirely exported in [`client::prelude`](./client/prelude/index.html). +//! The main public API is entirely exported in [`client::prelude`]. //! This should include everything necessary to write an IRC client or bot. //! //! # A Whirlwind Tour -//! The irc crate is divided into two main modules: [`client`](./client/index.html) and -//! [`proto`](./proto/index.html). As the names suggest, the `client` module captures the whole of +//! The irc crate is divided into two main modules: [`client`] and +//! [`proto`]. As the names suggest, the `client` module captures the whole of //! the client-side functionality, while the `proto` module features general components of an IRC //! protocol implementation that could in principle be used in either client or server software. //! Both modules feature a number of components that are low-level and can be used to build //! alternative APIs for the IRC protocol. For the average user, the higher-level components for an -//! IRC client are all re-exported in [`client::prelude`](./client/prelude/index.html). That module +//! IRC client are all re-exported in [`client::prelude`]. That module //! serves as the best starting point for a new user trying to understand the high-level API. //! //! # Example