From 570107d103ac21e254b6cc40c023c3d61e18dec3 Mon Sep 17 00:00:00 2001 From: David Hewitt <1939362+davidhewitt@users.noreply.github.com> Date: Tue, 17 May 2022 19:48:40 +0100 Subject: [PATCH] docs: fix nightly build --- src/exceptions.rs | 4 ++-- src/instance.rs | 21 +++++++++++---------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/exceptions.rs b/src/exceptions.rs index 6f7c8233..fb4be1e4 100644 --- a/src/exceptions.rs +++ b/src/exceptions.rs @@ -5,8 +5,8 @@ //! The structs in this module represent Python's built-in exceptions, while the modules comprise //! structs representing errors defined in Python code. //! -//! The latter are created with the [`import_exception`] macro, which you can use yourself -//! to import Python exceptions. +//! The latter are created with the [`import_exception`](crate::import_exception) macro, which you +//! can use yourself to import Python exceptions. use crate::{ffi, PyResult, Python}; use std::ffi::CStr; diff --git a/src/instance.rs b/src/instance.rs index 16d9d1a9..8850b452 100644 --- a/src/instance.rs +++ b/src/instance.rs @@ -541,8 +541,9 @@ impl Py { /// /// This is equivalent to the Python expression `self.attr_name`. /// - /// If calling this method becomes performance-critical, the [`intern!`] macro can be used - /// to intern `attr_name`, thereby avoiding repeated temporary allocations of Python strings. + /// If calling this method becomes performance-critical, the [`intern!`](crate::intern) macro + /// can be used to intern `attr_name`, thereby avoiding repeated temporary allocations of + /// Python strings. /// /// # Example: `intern!`ing the attribute name /// @@ -577,8 +578,8 @@ impl Py { /// /// This is equivalent to the Python expression `self.attr_name = value`. /// - /// To avoid repeated temporary allocations of Python strings, the [`intern!`] macro can be used - /// to intern `attr_name`. + /// To avoid repeated temporary allocations of Python strings, the [`intern!`](crate::intern) + /// macro can be used to intern `attr_name`. /// /// # Example: `intern!`ing the attribute name /// @@ -660,8 +661,8 @@ impl Py { /// /// This is equivalent to the Python expression `self.name(*args, **kwargs)`. /// - /// To avoid repeated temporary allocations of Python strings, the [`intern!`] macro can be used - /// to intern `name`. + /// To avoid repeated temporary allocations of Python strings, the [`intern!`](crate::intern) + /// macro can be used to intern `name`. pub fn call_method( &self, py: Python<'_>, @@ -691,8 +692,8 @@ impl Py { /// /// This is equivalent to the Python expression `self.name(*args)`. /// - /// To avoid repeated temporary allocations of Python strings, the [`intern!`] macro can be used - /// to intern `name`. + /// To avoid repeated temporary allocations of Python strings, the [`intern!`](crate::intern) + /// macro can be used to intern `name`. pub fn call_method1(&self, py: Python<'_>, name: N, args: A) -> PyResult where N: IntoPy>, @@ -705,8 +706,8 @@ impl Py { /// /// This is equivalent to the Python expression `self.name()`. /// - /// To avoid repeated temporary allocations of Python strings, the [`intern!`] macro can be used - /// to intern `name`. + /// To avoid repeated temporary allocations of Python strings, the [`intern!`](crate::intern) + /// macro can be used to intern `name`. pub fn call_method0(&self, py: Python<'_>, name: N) -> PyResult where N: IntoPy>,