From 2534b22bd55a134a6aba8aea3421a59a1f502ea2 Mon Sep 17 00:00:00 2001 From: John Carmack Date: Tue, 5 May 2026 08:53:08 -0700 Subject: [PATCH] inline Position in TS exports geojson::Position would otherwise export as a named TS alias `type Position = number[]`, which collides with downstream consumers that also have a Position type (e.g. fltsci's flights_api::Position discriminated union). Mark it specta(inline) so each usage emits the inline number[] shape and the name slot stays free for the consumer. --- src/position.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/position.rs b/src/position.rs index 01a2aa2..87256ea 100644 --- a/src/position.rs +++ b/src/position.rs @@ -30,6 +30,7 @@ use tinyvec::TinyVec; /// ``` #[derive(Debug, Clone, PartialEq, PartialOrd, Serialize, Deserialize)] #[cfg_attr(feature = "specta", derive(specta::Type))] +#[cfg_attr(feature = "specta", specta(inline))] pub struct Position(#[cfg_attr(feature = "specta", specta(type = Vec))] TinyVec<[f64; 2]>); impl Position {