Added int nanometer example in README

This commit is contained in:
adrien 2026-04-22 01:20:09 +02:00
parent 76c69448de
commit 49b56bda91

View File

@ -100,6 +100,7 @@ A `Scalar` type is parameterized by three things: the numeric type (`f64`, `i128
```zig ```zig
const Meter = Scalar(f64, .init(.{ .L = 1 }), .init(.{})); const Meter = Scalar(f64, .init(.{ .L = 1 }), .init(.{}));
const NanoMeter = Scalar(i64, .init(.{ .L = 1 }), .init(.{ .L = .n }));
const KiloMeter = Scalar(f64, .init(.{ .L = 1 }), .init(.{ .L = .k })); const KiloMeter = Scalar(f64, .init(.{ .L = 1 }), .init(.{ .L = .k }));
const Second = Scalar(f64, .init(.{ .T = 1 }), .init(.{})); const Second = Scalar(f64, .init(.{ .T = 1 }), .init(.{}));
const Velocity = Scalar(f64, .init(.{ .L = 1, .T = -1 }), .init(.{})); const Velocity = Scalar(f64, .init(.{ .L = 1, .T = -1 }), .init(.{}));