File tree 2 files changed +9
-5
lines changed
2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -479,11 +479,12 @@ struct array_caster {
479
479
using cast_op_type = movable_cast_op_type<T_>;
480
480
481
481
static constexpr auto name
482
- = const_name<Resizable>(const_name(" " ), const_name(" Annotated[" ))
482
+ = const_name<Resizable>(const_name(" " ), const_name(" typing. Annotated[" ))
483
483
+ io_name(" collections.abc.Sequence" , " list" ) + const_name(" [" ) + value_conv::name
484
484
+ const_name(" ]" )
485
- + const_name<Resizable>(
486
- const_name (" " ), const_name(" , FixedSize(" ) + const_name<Size >() + const_name(" )]" ));
485
+ + const_name<Resizable>(const_name(" " ),
486
+ const_name (" , \" FixedSize(" ) + const_name<Size >()
487
+ + const_name(" )\" ]" ));
487
488
};
488
489
489
490
template <typename Type, size_t Size >
Original file line number Diff line number Diff line change @@ -44,10 +44,13 @@ def test_array(doc):
44
44
assert m .load_array (lst )
45
45
assert m .load_array (tuple (lst ))
46
46
47
- assert doc (m .cast_array ) == "cast_array() -> Annotated[list[int], FixedSize(2)]"
47
+ assert (
48
+ doc (m .cast_array )
49
+ == 'cast_array() -> typing.Annotated[list[int], "FixedSize(2)"]'
50
+ )
48
51
assert (
49
52
doc (m .load_array )
50
- == " load_array(arg0: Annotated[collections.abc.Sequence[int], FixedSize(2)]) -> bool"
53
+ == ' load_array(arg0: typing. Annotated[collections.abc.Sequence[int], " FixedSize(2)" ]) -> bool'
51
54
)
52
55
53
56
You can’t perform that action at this time.
0 commit comments