Skip to content

Commit

Permalink
riscv-semihosting: fix ambiguous documentation link
Browse files Browse the repository at this point in the history
Fix the following warning when generating the crate documentation:

warning: `syscall` is both a function and a macro
   --> riscv-semihosting/src/lib.rs:212:15
    |
212 | /// Same as [`syscall`].
    |               ^^^^^^^ ambiguous link
    |
    = note: `#[warn(rustdoc::broken_intra_doc_links)]` on by default
help: to link to the function, add parentheses
    |
212 | /// Same as [`syscall()`].
    |                      ++
help: to link to the macro, add an exclamation mark
    |
212 | /// Same as [`syscall!`].
    |                      +
  • Loading branch information
clopez-oc committed Jul 30, 2024
1 parent 5612138 commit f97d34f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion riscv-semihosting/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ pub unsafe fn syscall<T>(nr: usize, arg: &T) -> usize {
///
/// # Safety
///
/// Same as [`syscall`].
/// Same as [`syscall()`].
#[inline(always)]
pub unsafe fn syscall1(_nr: usize, _arg: usize) -> usize {
match () {
Expand Down

0 comments on commit f97d34f

Please sign in to comment.