@@ -527,42 +527,31 @@ typedef __char32_t char32_t;
527
527
# define _LIBCPP_TEMPLATE_DATA_VIS
528
528
# define _LIBCPP_ENUM_VIS
529
529
530
- # endif // defined(_LIBCPP_OBJECT_FORMAT_COFF)
530
+ # else
531
531
532
- # ifndef _LIBCPP_HIDDEN
533
532
# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
534
- # define _LIBCPP_HIDDEN __attribute__ ((__visibility__(" hidden " )))
533
+ # define _LIBCPP_VISIBILITY ( vis ) __attribute__((__visibility__(vis )))
535
534
# else
536
- # define _LIBCPP_HIDDEN
535
+ # define _LIBCPP_VISIBILITY ( vis )
537
536
# endif
538
- # endif
539
537
540
- # ifndef _LIBCPP_METHOD_TEMPLATE_IMPLICIT_INSTANTIATION_VIS
538
+ # define _LIBCPP_HIDDEN _LIBCPP_VISIBILITY (" hidden" )
539
+ # define _LIBCPP_FUNC_VIS _LIBCPP_VISIBILITY (" default" )
540
+ # define _LIBCPP_TYPE_VIS _LIBCPP_VISIBILITY (" default" )
541
+ # define _LIBCPP_TEMPLATE_DATA_VIS _LIBCPP_VISIBILITY (" default" )
542
+ # define _LIBCPP_EXPORTED_FROM_ABI _LIBCPP_VISIBILITY (" default" )
543
+ # define _LIBCPP_OVERRIDABLE_FUNC_VIS _LIBCPP_VISIBILITY (" default" )
544
+ # define _LIBCPP_EXCEPTION_ABI _LIBCPP_VISIBILITY (" default" )
545
+ # define _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS _LIBCPP_VISIBILITY (" default" )
546
+ # define _LIBCPP_CLASS_TEMPLATE_INSTANTIATION_VIS
547
+
541
548
# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
542
549
// The inline should be removed once PR32114 is resolved
543
550
# define _LIBCPP_METHOD_TEMPLATE_IMPLICIT_INSTANTIATION_VIS inline _LIBCPP_HIDDEN
544
551
# else
545
552
# define _LIBCPP_METHOD_TEMPLATE_IMPLICIT_INSTANTIATION_VIS
546
553
# endif
547
- # endif
548
-
549
- # ifndef _LIBCPP_FUNC_VIS
550
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
551
- # define _LIBCPP_FUNC_VIS __attribute__ ((__visibility__(" default" )))
552
- # else
553
- # define _LIBCPP_FUNC_VIS
554
- # endif
555
- # endif
556
554
557
- # ifndef _LIBCPP_TYPE_VIS
558
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
559
- # define _LIBCPP_TYPE_VIS __attribute__ ((__visibility__(" default" )))
560
- # else
561
- # define _LIBCPP_TYPE_VIS
562
- # endif
563
- # endif
564
-
565
- # ifndef _LIBCPP_TEMPLATE_VIS
566
555
# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
567
556
# if __has_attribute(__type_visibility__)
568
557
# define _LIBCPP_TEMPLATE_VIS __attribute__ ((__type_visibility__(" default" )))
@@ -572,55 +561,14 @@ typedef __char32_t char32_t;
572
561
# else
573
562
# define _LIBCPP_TEMPLATE_VIS
574
563
# endif
575
- # endif
576
564
577
- # ifndef _LIBCPP_TEMPLATE_DATA_VIS
578
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
579
- # define _LIBCPP_TEMPLATE_DATA_VIS __attribute__ ((__visibility__(" default" )))
580
- # else
581
- # define _LIBCPP_TEMPLATE_DATA_VIS
582
- # endif
583
- # endif
584
-
585
- # ifndef _LIBCPP_EXPORTED_FROM_ABI
586
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
587
- # define _LIBCPP_EXPORTED_FROM_ABI __attribute__ ((__visibility__(" default" )))
588
- # else
589
- # define _LIBCPP_EXPORTED_FROM_ABI
590
- # endif
591
- # endif
592
-
593
- # ifndef _LIBCPP_OVERRIDABLE_FUNC_VIS
594
- # define _LIBCPP_OVERRIDABLE_FUNC_VIS _LIBCPP_FUNC_VIS
595
- # endif
596
-
597
- # ifndef _LIBCPP_EXCEPTION_ABI
598
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
599
- # define _LIBCPP_EXCEPTION_ABI __attribute__ ((__visibility__(" default" )))
600
- # else
601
- # define _LIBCPP_EXCEPTION_ABI
602
- # endif
603
- # endif
604
-
605
- # ifndef _LIBCPP_ENUM_VIS
606
565
# if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS) && __has_attribute(__type_visibility__)
607
566
# define _LIBCPP_ENUM_VIS __attribute__ ((__type_visibility__(" default" )))
608
567
# else
609
568
# define _LIBCPP_ENUM_VIS
610
569
# endif
611
- # endif
612
570
613
- # ifndef _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS
614
- # if !defined(_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS)
615
- # define _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS __attribute__ ((__visibility__(" default" )))
616
- # else
617
- # define _LIBCPP_EXTERN_TEMPLATE_TYPE_VIS
618
- # endif
619
- # endif
620
-
621
- # ifndef _LIBCPP_CLASS_TEMPLATE_INSTANTIATION_VIS
622
- # define _LIBCPP_CLASS_TEMPLATE_INSTANTIATION_VIS
623
- # endif
571
+ # endif // defined(_LIBCPP_OBJECT_FORMAT_COFF)
624
572
625
573
# if __has_attribute(internal_linkage)
626
574
# define _LIBCPP_INTERNAL_LINKAGE __attribute__ ((internal_linkage))
0 commit comments