File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -34,6 +34,11 @@ module Impl {
3434 exists ( this .getField ( pragma [ only_bind_into ] ( pos ) ) )
3535 }
3636
37+ /**
38+ * Gets the struct matched by this pattern.
39+ */
40+ Struct getStruct ( ) { result = PathResolution:: resolvePath ( this .getPath ( ) ) }
41+
3742 /** Gets the tuple field that matches the `pos`th pattern of this pattern. */
3843 pragma [ nomagic]
3944 TupleField getTupleField ( int pos ) {
Original file line number Diff line number Diff line change @@ -16,8 +16,7 @@ private class PoemHandlerParam extends RemoteSource::Range {
1616 exists ( TupleStructPat param , Type t |
1717 this .asPat ( ) .getPat ( ) = param .getAField ( ) and
1818 t = inferType ( param ) and
19- t .( StructType ) .asItemNode ( ) .( Addressable ) .getCanonicalPath ( ) =
20- [ "poem::web::query::Query" , "poem::web::path::Path" ]
19+ param .getStruct ( ) .getCanonicalPath ( ) = [ "poem::web::query::Query" , "poem::web::path::Path" ]
2120 )
2221 }
2322}
You can’t perform that action at this time.
0 commit comments