File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -336,7 +336,7 @@ where
336336 /// Like `platform_info_in`, but uses the global allocator.
337337 #[ cfg( feature = "alloc" ) ]
338338 pub fn platform_info ( & self ) -> AcpiResult < PlatformInfo < alloc:: alloc:: Global > > {
339- PlatformInfo :: new_in ( self , alloc :: alloc :: Global )
339+ PlatformInfo :: new ( self )
340340 }
341341
342342 /// Convenience method for contructing a [`PlatformInfo`](crate::platform::PlatformInfo). This is one of the
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ use crate::{
66 madt:: Madt ,
77 AcpiError ,
88 AcpiHandler ,
9+ AcpiResult ,
910 AcpiTables ,
1011 ManagedSlice ,
1112 PowerProfile ,
@@ -100,11 +101,21 @@ where
100101 */
101102}
102103
104+ #[ cfg( feature = "alloc" ) ]
105+ impl < ' a > PlatformInfo < ' a , alloc:: alloc:: Global > {
106+ pub fn new < H > ( tables : & AcpiTables < H > ) -> AcpiResult < Self >
107+ where
108+ H : AcpiHandler ,
109+ {
110+ Self :: new_in ( tables, alloc:: alloc:: Global )
111+ }
112+ }
113+
103114impl < ' a , A > PlatformInfo < ' a , A >
104115where
105116 A : Allocator + Clone ,
106117{
107- pub fn new_in < H > ( tables : & AcpiTables < H > , allocator : A ) -> crate :: AcpiResult < Self >
118+ pub fn new_in < H > ( tables : & AcpiTables < H > , allocator : A ) -> AcpiResult < Self >
108119 where
109120 H : AcpiHandler ,
110121 {
You can’t perform that action at this time.
0 commit comments