Skip to content

Commit 41f24c2

Browse files
committed
fmt cleanup
1 parent 44ebca9 commit 41f24c2

4 files changed

Lines changed: 9 additions & 15 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "sql_docs"
3-
version = "1.2.1"
3+
version = "1.3.0"
44
edition = "2024"
55
description = "A crate for parsing comments from sql files and using them for documentation generation"
66
documentation = "https://docs.rs/sql_docs"

src/docs.rs

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -355,12 +355,7 @@ fn schema_and_table(name: &ObjectName) -> Result<(Option<String>, String), DocEr
355355

356356
#[cfg(test)]
357357
mod tests {
358-
use alloc::{
359-
borrow::ToOwned,
360-
boxed::Box,
361-
string::String,
362-
vec,
363-
};
358+
use alloc::{borrow::ToOwned, boxed::Box, string::String, vec};
364359
#[cfg(feature = "std")]
365360
use core::fmt;
366361

@@ -391,7 +386,7 @@ mod tests {
391386
assert_eq!(sql_doc_val_column.name(), "id");
392387
}
393388

394-
#[cfg(feature = "std")]
389+
#[cfg(feature = "std")]
395390
fn single_line_comments_sql() -> &'static str {
396391
"-- Users table stores user account information
397392
CREATE TABLE users (
@@ -420,7 +415,7 @@ CREATE TABLE posts (
420415
);"
421416
}
422417

423-
#[cfg(feature = "std")]
418+
#[cfg(feature = "std")]
424419
fn multiline_comments_sql() -> &'static str {
425420
r"/* Users table stores user account information
426421
multiline */
@@ -811,7 +806,6 @@ CREATE TABLE posts (
811806
}
812807
#[cfg(feature = "std")]
813808
impl FailOnNthWrite {
814-
815809
fn new(fail_at: usize) -> Self {
816810
Self { fail_at, writes: 0, sink: String::new() }
817811
}

src/sql_doc.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ enum SqlFileDocSource<'a> {
293293
}
294294

295295
#[cfg(feature = "std")]
296-
impl<'a> SqlDocBuilder<'a> {
296+
impl SqlDocBuilder<'_> {
297297
/// Method for adding an item to the deny list
298298
///
299299
/// # Parameters
@@ -526,11 +526,11 @@ mod tests {
526526
use sqlparser::dialect::{GenericDialect, PostgreSqlDialect};
527527

528528
#[cfg(feature = "std")]
529-
use crate::{LeadingCommentCapture, MultiFlatten, SqlDocBuilder, docs::{ColumnDoc, TableDoc}};
530529
use crate::{
531-
SqlDoc,
532-
error::DocError,
530+
LeadingCommentCapture, MultiFlatten, SqlDocBuilder,
531+
docs::{ColumnDoc, TableDoc},
533532
};
533+
use crate::{SqlDoc, error::DocError};
534534

535535
#[cfg(feature = "std")]
536536
#[test]

0 commit comments

Comments
 (0)