radn-rs/src/core/points.rs

13 lines
401 B
Rust

use super::*;
pub trait TakesPoints<'a, Ctx: 'a + Context> {
fn take<A: Mentionable<'a, Ctx>>(&mut self, point: &Point<'a, Ctx, A>);
}
impl<'a, Ctx: 'a + Context> TakesPoints<'a, Ctx> for Vec<u8> {
/// The only natural implementation, as used in [`Mentionable::topology`].
fn take<A: Mentionable<'a, Ctx>>(&mut self, point: &Point<'a, Ctx, A>) {
self.extend(point.point)
}
}