Skip to content

Commit 272152e

Browse files
committed
Annotated[Any, CppTypePybind11("cpp_namespace::UserType")] based on a suggestion by @sizmailov
#4888 (comment)
1 parent ea00323 commit 272152e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/pybind11/pybind11.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@ class cpp_function : public function {
494494
std::string tname(t->name());
495495
detail::clean_type_id(tname);
496496
if (detail::cpp_name_needs_typing_annotated(tname.c_str())) {
497-
signature += "Annotated[Any, \"" + tname + "\"]";
497+
signature += "Annotated[Any, CppTypePybind11(\"" + tname + "\")]";
498498
} else {
499499
signature += tname;
500500
}

0 commit comments

Comments
 (0)