Skip to content

Commit

Permalink
docs: warn about missing docs for jj-lib crate
Browse files Browse the repository at this point in the history
  • Loading branch information
arxanas committed Jul 10, 2023
1 parent 24c7b59 commit 54dba51
Show file tree
Hide file tree
Showing 46 changed files with 92 additions and 2 deletions.
2 changes: 2 additions & 0 deletions lib/src/backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::collections::BTreeMap;
use std::fmt::{Debug, Error, Formatter};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/commit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::cmp::Ordering;
use std::fmt::{Debug, Error, Formatter};
use std::hash::{Hash, Hasher};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/commit_builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::sync::Arc;

use crate::backend::{self, BackendResult, ChangeId, CommitId, Signature, TreeId};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/conflicts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::hash::Hash;
use std::io::Write;

Expand Down
2 changes: 2 additions & 0 deletions lib/src/dag_walk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{BinaryHeap, HashMap, HashSet};
use std::hash::Hash;
use std::{iter, mem};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/default_index_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::cmp::{max, min, Ordering, Reverse};
use std::collections::{BTreeMap, BTreeSet, BinaryHeap, Bound, HashMap, HashSet};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/default_revset_engine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::cmp::{Ordering, Reverse};
use std::collections::{BinaryHeap, HashSet};
use std::fmt;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/default_revset_graph_iterator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::cmp::min;
use std::collections::{BTreeMap, HashSet};

Expand Down
2 changes: 2 additions & 0 deletions lib/src/default_submodule_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::path::{Path, PathBuf};

use crate::submodule_store::SubmoduleStore;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/diff.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::cmp::{max, min, Ordering};
use std::collections::{BTreeMap, HashMap};
use std::fmt::{Debug, Formatter};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/file_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fs::File;
use std::path::{Component, Path, PathBuf};
use std::{io, iter};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/files.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::VecDeque;
use std::fmt::{Debug, Error, Formatter};
use std::ops::Range;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/git.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{BTreeMap, HashMap, HashSet};
use std::default::Default;
use std::io::Read;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/git_backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::fmt::{Debug, Error, Formatter};
use std::io::{Cursor, Read};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/gitignore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fs::File;
use std::io::Read;
use std::path::PathBuf;
Expand Down
3 changes: 3 additions & 0 deletions lib/src/hex_util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

fn to_reverse_hex_digit(b: u8) -> Option<u8> {
let value = match b {
b'0'..=b'9' => b - b'0',
Expand Down
2 changes: 2 additions & 0 deletions lib/src/id_prefix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::iter;
use std::marker::PhantomData;
use std::rc::Rc;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/index.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::fmt::Debug;
use std::sync::Arc;
Expand Down
3 changes: 2 additions & 1 deletion lib/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![deny(unused_must_use)]
//! Jujutsu version control system.
#![warn(missing_docs)]
#![deny(unused_must_use)]

#[macro_use]
mod content_hash;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/local_backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::fmt::Debug;
use std::fs;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/lock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

#[cfg_attr(unix, path = "lock/unix.rs")]
#[cfg_attr(not(unix), path = "lock/fallback.rs")]
mod platform;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/lock/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fs::File;
use std::path::PathBuf;

Expand Down
2 changes: 1 addition & 1 deletion lib/src/matchers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(dead_code)]
#![allow(dead_code, missing_docs)]

use std::collections::{HashMap, HashSet};
use std::iter;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/merge.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::HashMap;
use std::hash::Hash;

Expand Down
2 changes: 2 additions & 0 deletions lib/src/nightly_shims.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

#[cfg(feature = "map_first_last")]
pub trait BTreeMapExt<K, V> {
fn first_key(&self) -> Option<&K>;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/op_heads_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::HashSet;
use std::fmt::Debug;
use std::sync::Arc;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/op_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{BTreeMap, HashMap, HashSet};
use std::fmt::{Debug, Error, Formatter};
use std::slice;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/operation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::cmp::Ordering;
use std::collections::HashSet;
use std::fmt::{Debug, Error, Formatter};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/protos/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#![allow(missing_docs)]

pub mod git_store {
include!("git_store.rs");
}
Expand Down
2 changes: 2 additions & 0 deletions lib/src/refs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use crate::backend::CommitId;
use crate::index::Index;
use crate::merge::trivial_merge;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/repo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{HashMap, HashSet};
use std::fmt::{Debug, Formatter};
use std::fs;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/repo_path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fmt::{Debug, Error, Formatter};
use std::path::{Component, Path, PathBuf};

Expand Down
2 changes: 2 additions & 0 deletions lib/src/revset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::HashMap;
use std::convert::Infallible;
use std::ops::Range;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/rewrite.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{HashMap, HashSet};
use std::sync::Arc;

Expand Down
2 changes: 2 additions & 0 deletions lib/src/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::path::Path;
use std::sync::{Arc, Mutex};

Expand Down
2 changes: 2 additions & 0 deletions lib/src/simple_op_heads_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fmt::{Debug, Formatter};
use std::fs;
use std::path::{Path, PathBuf};
Expand Down
2 changes: 2 additions & 0 deletions lib/src/simple_op_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::BTreeMap;
use std::fmt::Debug;
use std::fs;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/stacked_table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
//! a parent file, and the parent may have its own parent, and so on. The child
//! file then represents the union of the entries.
#![allow(missing_docs)]

use std::cmp::Ordering;
use std::collections::{BTreeMap, HashMap};
use std::fs::File;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::any::Any;
use std::collections::HashMap;
use std::io::Read;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/submodule_store.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fmt::Debug;

pub trait SubmoduleStore: Send + Sync + Debug {
Expand Down
2 changes: 2 additions & 0 deletions lib/src/transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::sync::Arc;

use crate::backend::Timestamp;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/tree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::fmt::{Debug, Error, Formatter};
use std::hash::{Hash, Hasher};
use std::io::Read;
Expand Down
2 changes: 2 additions & 0 deletions lib/src/tree_builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::BTreeMap;
use std::sync::Arc;

Expand Down
2 changes: 2 additions & 0 deletions lib/src/view.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![allow(missing_docs)]

use std::collections::{BTreeMap, HashMap, HashSet};
use std::fmt;

Expand Down
Loading

0 comments on commit 54dba51

Please sign in to comment.