Skip to content

Commit eab5694

Browse files
committed
add Warning to other sort fns
1 parent 5ec9552 commit eab5694

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

examples/forward_simulation.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
* and numbers of crossovers, etc.., from being entered
1919
* on the command line.
2020
*/
21-
use clap::{Command, Arg};
21+
use clap::{Arg, Command};
2222
use rand::rngs::StdRng;
2323
use rand::Rng;
2424
use rand::SeedableRng;

examples/tree_traversals.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use clap::{Command, Arg};
1+
use clap::{Arg, Command};
22
use tskit::prelude::*;
33

44
// "Manual" traversal from samples to root

src/table_collection.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -598,6 +598,12 @@ impl TableCollection {
598598
/// Sort the tables.
599599
/// The [``bookmark``](crate::types::Bookmark) can
600600
/// be used to affect where sorting starts from for each table.
601+
///
602+
/// # Warning
603+
///
604+
/// As of `0.7.0`, this function does not sort the individual table!
605+
/// See
606+
/// [``topological_sort_individuals``](crate::TableCollection::topological_sort_individuals).
601607
pub fn sort(&mut self, start: &Bookmark, options: TableSortOptions) -> TskReturnValue {
602608
let rv = unsafe {
603609
ll_bindings::tsk_table_collection_sort(
@@ -612,6 +618,12 @@ impl TableCollection {
612618

613619
/// Fully sort all functions.
614620
/// Implemented via a call to [``sort``](crate::TableCollection::sort).
621+
///
622+
/// # Warning
623+
///
624+
/// As of `0.7.0`, this function does not sort the individual table!
625+
/// See
626+
/// [``topological_sort_individuals``](crate::TableCollection::topological_sort_individuals).
615627
pub fn full_sort(&mut self, options: TableSortOptions) -> TskReturnValue {
616628
let b = Bookmark::new();
617629
self.sort(&b, options)

0 commit comments

Comments
 (0)