Minor rustdoc corrections.

This commit is contained in:
parazyd
2022-05-22 21:12:59 +02:00
parent 15189037dc
commit 4c9570583e
5 changed files with 12 additions and 7 deletions

View File

@@ -39,6 +39,10 @@ fix: token_lists
clippy: token_lists
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) clippy --release --all-features --all
rustdoc: token_lists
RUSTFLAGS="$(RUSTFLAGS)" $(CARGO) doc --release --workspace --all-features \
--no-deps --document-private-items
# zkas source files which we want to compile for tests
VM_SRC = proof/arithmetic.zk proof/mint.zk proof/burn.zk example/simple.zk
VM_BIN = $(VM_SRC:=.bin)
@@ -65,4 +69,4 @@ uninstall:
rm -f $(DESTDIR)$(PREFIX)/bin/$$i; \
done;
.PHONY: all check fix clippy test test-tx clean install uninstall
.PHONY: all check fix clippy rustdoc test test-tx clean install uninstall

View File

@@ -4,7 +4,7 @@ use crate::util::{
time::Timestamp,
};
/// This struct represents additional [`Block`] information used by
/// This struct represents additional [`Block`](super::Block) information used by
/// the consensus protocol
#[derive(Debug, Clone, PartialEq, SerialEncodable, SerialDecodable)]
pub struct Metadata {
@@ -20,7 +20,7 @@ impl Metadata {
}
}
/// This struct represents [`Block`] information used by the Ouroboros
/// This struct represents [`Block`](super::Block) information used by the Ouroboros
/// Praos consensus protocol.
#[derive(Debug, Clone, PartialEq, SerialEncodable, SerialDecodable)]
pub struct OuroborosMetadata {
@@ -38,7 +38,7 @@ impl OuroborosMetadata {
}
}
/// This struct represents [`Block`] information used by the Streamlet
/// This struct represents [`Block`](super::Block) information used by the Streamlet
/// consensus protocol.
#[derive(Debug, Clone, SerialEncodable, SerialDecodable)]
pub struct StreamletMetadata {

View File

@@ -63,7 +63,8 @@ impl TryFrom<Url> for TransportName {
/// The `Transport` trait serves as a base for implementing transport protocols.
/// Base transports can optionally be upgraded with TLS in order to support encryption.
/// The implementation of our TLS authentication can be found in the [`upgrade_tls`] module.
/// The implementation of our TLS authentication can be found in the
/// [`upgrade_tls`](TlsUpgrade) module.
pub trait Transport {
type Acceptor;
type Connector;

View File

@@ -72,7 +72,7 @@ async fn accept(
Ok(())
}
/// Wrapper function around [`accept`] to take the incoming connection and
/// Wrapper function around [`accept()`] to take the incoming connection and
/// pass it forward.
async fn run_accept_loop(
listener: Box<dyn TransportListener>,

View File

@@ -92,7 +92,7 @@ impl Runtime {
Ok(Self { instance, env })
}
/// Run the hardcoded [ENTRYPOINT] function with the given payload as input.
/// Run the hardcoded `ENTRYPOINT` function with the given payload as input.
pub fn run(&mut self, payload: &[u8]) -> Result<()> {
// Get module linear memory
let memory = self.memory()?;