@@ -867,18 +867,27 @@ def test_domain_cpp_ast_function_definitions() -> None:
867867 # https://github.com/sphinx-doc/sphinx/issues/14026 Unicode
868868 # identifiers
869869 check ('function' , 'void f(int *const ξ)' , {1 : 'f__iPC' , 2 : '1fPCi' })
870- check ('function' , 'template<typename Ξ> Ξ ξcompute(Ξ ξ)' ,
871- {2 : 'I0E8ξcompute1Ξ' ,
872- 3 : 'I0E8ξcompute1Ξ' ,
873- 4 : 'I0E8ξcompute1Ξ1Ξ' })
874- check ('function' , 'ΨStruct ψcompute(double i)' ,
875- {1 : 'ψcompute__double' ,
876- 2 : '8ψcomputed' ,
877- 3 : '8ψcomputed' ,
878- 4 : '8ψcomputed' })
879- check ('function' , 'norm₂(V x)' , {1 : 'norm₂__V' , 2 : '5norm₂1V' , 3 : '5norm₂1V' , 4 : '5norm₂1V' })
870+ check (
871+ 'function' ,
872+ 'template<typename Ξ> Ξ ξcompute(Ξ ξ)' ,
873+ {2 : 'I0E8ξcompute1Ξ' , 3 : 'I0E8ξcompute1Ξ' , 4 : 'I0E8ξcompute1Ξ1Ξ' },
874+ )
875+ check (
876+ 'function' ,
877+ 'ΨStruct ψcompute(double i)' ,
878+ {1 : 'ψcompute__double' , 2 : '8ψcomputed' , 3 : '8ψcomputed' , 4 : '8ψcomputed' },
879+ )
880+ check (
881+ 'function' ,
882+ 'norm₂(V x)' ,
883+ {1 : 'norm₂__V' , 2 : '5norm₂1V' , 3 : '5norm₂1V' , 4 : '5norm₂1V' },
884+ )
880885 check ('function' , '∇(V x)' , {1 : '∇__V' , 2 : '1∇1V' , 3 : '1∇1V' , 4 : '1∇1V' })
881- check ('function' , 'compute∂(V x)' , {1 : 'compute∂__V' , 2 : '8compute∂1V' , 3 : '8compute∂1V' , 4 : '8compute∂1V' })
886+ check (
887+ 'function' ,
888+ 'compute∂(V x)' ,
889+ {1 : 'compute∂__V' , 2 : '8compute∂1V' , 3 : '8compute∂1V' , 4 : '8compute∂1V' },
890+ )
882891
883892 # TODO: make tests for functions in a template, e.g., Test<int&&()>
884893 # such that the id generation for function type types is correct.
@@ -1072,9 +1081,12 @@ def test_domain_cpp_ast_class_definitions() -> None:
10721081 # Test derived from
10731082 # https://github.com/sphinx-doc/sphinx/issues/14026 Unicode
10741083 # identifier
1075- check ('class' , 'public ΨStruct' , {1 : 'ΨStruct' , 2 : '7ΨStruct' ,
1076- 3 : '7ΨStruct' , 4 : '7ΨStruct' },
1077- output = '{key}ΨStruct' )
1084+ check (
1085+ 'class' ,
1086+ 'public ΨStruct' ,
1087+ {1 : 'ΨStruct' , 2 : '7ΨStruct' , 3 : '7ΨStruct' , 4 : '7ΨStruct' },
1088+ output = '{key}ΨStruct' ,
1089+ )
10781090
10791091
10801092def test_domain_cpp_ast_union_definitions () -> None :
0 commit comments