@@ -230,7 +230,7 @@ pub enum Advice {
230230 /// zeroed out if the address range is deallocated without first unwiring the pages (i.e.
231231 /// a munmap(2) without a preceding munlock(2) or the application quits). This is used
232232 /// with `madvise()` system call.
233- #[ cfg( any ( target_os = "macos" , target_os = "ios" ) ) ]
233+ #[ cfg( target_vendor = "apple" ) ]
234234 ZeroWiredPages = libc:: MADV_ZERO_WIRED_PAGES ,
235235}
236236
@@ -319,7 +319,7 @@ pub enum UncheckedAdvice {
319319 /// Using the returned value with conceptually write to the
320320 /// mapped pages, i.e. borrowing the mapping while the pages
321321 /// are still being freed results in undefined behaviour.
322- #[ cfg( any( target_os = "linux" , target_os = "macos" , target_os = "ios ") ) ]
322+ #[ cfg( any( target_os = "linux" , target_vendor = "apple " ) ) ]
323323 Free = libc:: MADV_FREE ,
324324
325325 /// **MADV_REMOVE** - Linux only (since Linux 2.6.16)
@@ -358,7 +358,7 @@ pub enum UncheckedAdvice {
358358 /// Using the returned value with conceptually write to the
359359 /// mapped pages, i.e. borrowing the mapping while the pages
360360 /// are still being freed results in undefined behaviour.
361- #[ cfg( any ( target_os = "macos" , target_os = "ios" ) ) ]
361+ #[ cfg( target_vendor = "apple" ) ]
362362 FreeReusable = libc:: MADV_FREE_REUSABLE ,
363363
364364 /// **MADV_FREE_REUSE** - Darwin only
@@ -372,7 +372,7 @@ pub enum UncheckedAdvice {
372372 /// Using the returned value with conceptually write to the
373373 /// mapped pages, i.e. borrowing the mapping while the pages
374374 /// are still being freed results in undefined behaviour.
375- #[ cfg( any ( target_os = "macos" , target_os = "ios" ) ) ]
375+ #[ cfg( target_vendor = "apple" ) ]
376376 FreeReuse = libc:: MADV_FREE_REUSE ,
377377}
378378
0 commit comments