2019-04-11 15:23:14 -07:00
|
|
|
use crate::common::*;
|
2019-04-11 12:30:29 -07:00
|
|
|
|
2019-04-11 23:58:08 -07:00
|
|
|
#[derive(Debug)]
|
2019-04-11 12:30:29 -07:00
|
|
|
pub struct Alias<'a> {
|
|
|
|
pub name: &'a str,
|
|
|
|
pub target: &'a str,
|
|
|
|
pub line_number: usize,
|
2019-04-11 15:57:34 -07:00
|
|
|
pub private: bool,
|
2019-04-11 12:30:29 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> Display for Alias<'a> {
|
2019-04-11 15:23:14 -07:00
|
|
|
fn fmt(&self, f: &mut Formatter) -> fmt::Result {
|
2019-04-11 12:30:29 -07:00
|
|
|
write!(f, "alias {} = {}", self.name, self.target)
|
|
|
|
}
|
|
|
|
}
|