ast: add ptr patterns
This commit is contained in:
		@@ -92,6 +92,8 @@ pub enum PatOp {
 | 
			
		||||
    Mut,
 | 
			
		||||
    /// Matches the dereference of a pointer (`&pat`)
 | 
			
		||||
    Ref,
 | 
			
		||||
    /// Matches the dereference of a raw pointer (`*pat`)
 | 
			
		||||
    Ptr,
 | 
			
		||||
    /// Matches a partial decomposition (`..rest`) or upper-bounded range (`..100`)
 | 
			
		||||
    Rest,
 | 
			
		||||
    /// Matches an exclusive bounded range (`0..100`)
 | 
			
		||||
@@ -176,7 +178,7 @@ pub enum TypedefKind {
 | 
			
		||||
pub enum Expr<A: Annotation = Span> {
 | 
			
		||||
    /// An identifier
 | 
			
		||||
    Id(FqPath),
 | 
			
		||||
    /// A meta-identifier
 | 
			
		||||
    /// An escaped token for macro binding
 | 
			
		||||
    MetId(String),
 | 
			
		||||
    /// A literal bool, string, char, or int
 | 
			
		||||
    Lit(Literal),
 | 
			
		||||
@@ -577,6 +579,7 @@ impl Display for PatOp {
 | 
			
		||||
            Self::Pub => "pub ",
 | 
			
		||||
            Self::Mut => "mut ",
 | 
			
		||||
            Self::Ref => "&",
 | 
			
		||||
            Self::Ptr => "*",
 | 
			
		||||
            Self::Rest => "..",
 | 
			
		||||
            Self::RangeEx => "..",
 | 
			
		||||
            Self::RangeIn => "..=",
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user