@@ -131,19 +131,26 @@ static_assert(verify(hep::phase, real_scalar, one)); // phase is dimensionless
131131
132132// Test quantity hierarchy conversions
133133// All specialized lengths can be implicitly converted up the hierarchy to generic length
134- static_assert (implicitly_convertible(hep::radiation_length, hep::length));
135134static_assert (implicitly_convertible(hep::decay_length, hep::length));
136- static_assert (implicitly_convertible(hep::interaction_length, hep::length));
137135static_assert (implicitly_convertible(hep::nuclear_interaction_length, hep::interaction_length));
138136
137+ // is_kind quantities form subkinds
138+ static_assert (!implicitly_convertible(hep::radiation_length, hep::length));
139+ static_assert (explicitly_convertible(hep::radiation_length, hep::length));
140+ static_assert (!implicitly_convertible(hep::interaction_length, hep::length));
141+ static_assert (explicitly_convertible(hep::interaction_length, hep::length));
142+
143+ static_assert (!implicitly_convertible(hep::proper_time, hep::duration));
144+ static_assert (explicitly_convertible(hep::proper_time, hep::duration));
145+ static_assert (!implicitly_convertible(hep::coordinate_time, hep::duration));
146+ static_assert (explicitly_convertible(hep::coordinate_time, hep::duration));
147+
139148// But cannot be implicitly converted between each other (different physical concepts!)
140149static_assert (!implicitly_convertible(hep::radiation_length, hep::decay_length));
141150static_assert (!implicitly_convertible(hep::decay_length, hep::interaction_length));
142151static_assert (!implicitly_convertible(hep::impact_parameter, hep::vertex_position));
143152
144153// Specialized times: proper_time vs coordinate_time are distinct
145- static_assert (implicitly_convertible(hep::proper_time, hep::duration));
146- static_assert (implicitly_convertible(hep::coordinate_time, hep::duration));
147154static_assert (!implicitly_convertible(hep::proper_time, hep::coordinate_time));
148155static_assert (!implicitly_convertible(hep::coordinate_time, hep::proper_time));
149156
0 commit comments