Skip to content

Commit

Permalink
Don't use gray for unit decompositions (#13)
Browse files Browse the repository at this point in the history
Despite being an official SI derived unit, gray is only meant to be used
in the context of ionizing radiation. There is no official SI unit for
specific heat capacity.
  • Loading branch information
tiffany352 committed Mar 30, 2024
1 parent 311b992 commit 70ad6fb
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion core/src/loader/load.rs
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,6 @@ pub(crate) fn load_defs(ctx: &mut Context, defs: Defs) -> Vec<String> {
decomposition_units.insert("tesla");
decomposition_units.insert("lumen");
decomposition_units.insert("lux");
decomposition_units.insert("gray");
decomposition_units.insert("katal");

let mut prefix_lookup = BTreeMap::new();
Expand Down
2 changes: 1 addition & 1 deletion core/tests/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ fn test_unary_operators() {

#[test]
fn test_equals() {
test("a = kg N / W^2", "1 second^2 / gray meter");
test("a = kg N / W^2", "1 second^4 / meter^3");
test(
"1 = kg",
"= is currently only used for inline unit definitions: expected unit, got 1",
Expand Down

0 comments on commit 70ad6fb

Please sign in to comment.