File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -115,21 +115,23 @@ mod mmap {
115115 #[ pyattr]
116116 const ACCESS_COPY : u32 = AccessMode :: Copy as u32 ;
117117
118+ #[ cfg( not( any( target_os = "wasi" , target_os = "redox" ) ) ) ]
118119 #[ pyattr( name = "PAGESIZE" , once) ]
119120 fn page_size ( _vm : & VirtualMachine ) -> usize {
120121 page_size:: get ( )
121122 }
122123
123- #[ pyattr( name = "error" , once) ]
124- fn error_type ( vm : & VirtualMachine ) -> PyTypeRef {
125- vm. ctx . exceptions . os_error . to_owned ( )
126- }
127-
124+ #[ cfg( not( any( target_os = "wasi" , target_os = "redox" ) ) ) ]
128125 #[ pyattr( name = "ALLOCATIONGRANULARITY" , once) ]
129126 fn granularity ( _vm : & VirtualMachine ) -> usize {
130127 page_size:: get_granularity ( )
131128 }
132129
130+ #[ pyattr( name = "error" , once) ]
131+ fn error_type ( vm : & VirtualMachine ) -> PyTypeRef {
132+ vm. ctx . exceptions . os_error . to_owned ( )
133+ }
134+
133135 #[ derive( Debug ) ]
134136 enum MmapObj {
135137 Write ( MmapMut ) ,
You can’t perform that action at this time.
0 commit comments