Skip to content

Commit

Permalink
chore: remove libs that panic
Browse files Browse the repository at this point in the history
  • Loading branch information
ematipico committed May 9, 2024
1 parent 6f80b7a commit bbb84f5
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions xtask/bench/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ biome_css_analyze = { workspace = true }
biome_css_formatter = { workspace = true }
biome_css_parser = { workspace = true }
biome_css_syntax = { workspace = true }
biome_diagnostics = { workspace = true }
biome_formatter = { workspace = true }
biome_js_analyze = { workspace = true }
biome_js_formatter = { workspace = true }
Expand Down
5 changes: 1 addition & 4 deletions xtask/bench/benches/analyzer-libs-css.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.css
https://cdn.jsdelivr.net/npm/[email protected]/dist/full.css
https://cdn.jsdelivr.net/npm/[email protected]/build/pure.css
https://raw.githubusercontent.com/Dogfalo/materialize/v1-dev/dist/css/materialize.css
https://raw.githubusercontent.com/jgthms/bulma/master/css/bulma.css
https://raw.githubusercontent.com/foundation/foundation-sites/develop/dist/css/foundation.css
https://raw.githubusercontent.com/Semantic-Org/Semantic-UI/master/dist/semantic.css
https://raw.githubusercontent.com/tachyons-css/tachyons/main/css/tachyons.css
https://raw.githubusercontent.com/tachyons-css/tachyons/main/css/tachyons.css
6 changes: 5 additions & 1 deletion xtask/bench/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ mod test_case;
use crate::language::FormatNode;
pub use crate::language::Parse;
pub use crate::test_case::TestCase;
use biome_diagnostics::{print_diagnostic_to_string, Error};
use biome_formatter::Printed;
use biome_rowan::NodeCache;
use criterion::measurement::WallTime;
Expand Down Expand Up @@ -37,7 +38,10 @@ pub fn bench_parser_group(group: &mut BenchmarkGroup<WallTime>, test_case: TestC
&code,
|b, _| {
b.iter(|| {
black_box(parse.parse());
let result = black_box(parse.parse());
for diagnostic in result.into_diagnostics() {
println!("{}", print_diagnostic_to_string(&Error::from(diagnostic)));
}
})
},
);
Expand Down

0 comments on commit bbb84f5

Please sign in to comment.