File tree Expand file tree Collapse file tree 3 files changed +12
-1
lines changed
tests/src/integration/class Expand file tree Collapse file tree 3 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -196,7 +196,8 @@ impl<'a> Function<'a> {
196196 }
197197
198198 fn build_returns ( & self ) -> Option < TokenStream > {
199- self . output . as_ref ( ) . map ( |output| {
199+ self . output . cloned ( ) . map ( |mut output| {
200+ output. drop_lifetimes ( ) ;
200201 quote ! {
201202 . returns(
202203 <#output as :: ext_php_rs:: convert:: IntoZval >:: TYPE ,
Original file line number Diff line number Diff line change 1212assert ($ class ->getString () === 'dolor et ' );
1313$ class ->selfRef ("foo " );
1414assert ($ class ->getString () === 'Changed to foo ' );
15+ $ class ->selfMultiRef ("bar " );
16+ assert ($ class ->getString () === 'Changed to bar ' );
1517
1618assert ($ class ->getNumber () === 2022 );
1719$ class ->setNumber (2023 );
Original file line number Diff line number Diff line change @@ -49,6 +49,14 @@ impl TestClass {
4949 self_. string = format ! ( "Changed to {val}" ) ;
5050 self_
5151 }
52+
53+ pub fn self_multi_ref < ' a > (
54+ self_ : & ' a mut ZendClassObject < TestClass > ,
55+ val : & str ,
56+ ) -> & ' a mut ZendClassObject < TestClass > {
57+ self_. string = format ! ( "Changed to {val}" ) ;
58+ self_
59+ }
5260}
5361
5462#[ php_function]
You can’t perform that action at this time.
0 commit comments