// Copyright (C) 2016 Symtern Project Contributors // // Licensed under the Apache License, Version 2.0 or the MIT // license , // at your option. This file may not be copied, modified, or // distributed except according to those terms. //! Example for lib.rs to demonstrate that symbol types implement Copy. extern crate symtern; use symtern::prelude::*; use symtern::Pool; /// Take ownership of a value, consuming it. fn consume(_: T) {} fn main() { let mut pool = Pool::::new(); let sym = pool.intern("xyz").unwrap(); consume(sym); println!("The symbol is still valid: {:?}", pool.resolve(sym)); }