Skip to content

Commit bc7848d

Browse files
author
izaid
committed
Updates to match libdynd
1 parent addbb72 commit bc7848d

3 files changed

Lines changed: 9 additions & 4 deletions

File tree

dynd/include/callables/assign_from_pyobject_callable.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ namespace nd {
187187
public:
188188
assign_from_pyobject_callable()
189189
: dynd::nd::base_callable(dynd::ndt::make_type<dynd::ndt::callable_type>(
190-
ndt::make_type<ndt::tuple_type>(), {dynd::ndt::make_type<pyobject_type>()}))
190+
ndt::make_type<ndt::tuple_type>(true), {dynd::ndt::make_type<pyobject_type>()}))
191191
{
192192
}
193193

@@ -270,7 +270,7 @@ namespace nd {
270270
public:
271271
assign_from_pyobject_callable()
272272
: dynd::nd::base_callable(dynd::ndt::make_type<dynd::ndt::callable_type>(
273-
ndt::make_type<ndt::struct_type>(), {dynd::ndt::make_type<pyobject_type>()}))
273+
ndt::make_type<ndt::struct_type>(true), {dynd::ndt::make_type<pyobject_type>()}))
274274
{
275275
}
276276

dynd/include/callables/assign_to_pyobject_callable.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ namespace nd {
213213
public:
214214
assign_to_pyobject_callable()
215215
: dynd::nd::base_callable(dynd::ndt::make_type<dynd::ndt::callable_type>(
216-
dynd::ndt::make_type<pyobject_type>(), {dynd::ndt::make_type<ndt::tuple_type>()}))
216+
dynd::ndt::make_type<pyobject_type>(), {dynd::ndt::make_type<ndt::tuple_type>(true)}))
217217
{
218218
}
219219

@@ -261,7 +261,7 @@ namespace nd {
261261
public:
262262
assign_to_pyobject_callable()
263263
: dynd::nd::base_callable(dynd::ndt::make_type<dynd::ndt::callable_type>(
264-
dynd::ndt::make_type<pyobject_type>(), {dynd::ndt::make_type<ndt::struct_type>()}))
264+
dynd::ndt::make_type<pyobject_type>(), {dynd::ndt::make_type<ndt::struct_type>(true)}))
265265
{
266266
}
267267

dynd/include/types/pyobject_type.hpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ class PYDYND_API pyobject_type : public dynd::ndt::base_type {
1616
void print_type(std::ostream &o) const;
1717
void print_data(std::ostream &o, const char *arrmeta, const char *data) const;
1818

19+
bool match(const dynd::ndt::type &candidate_tp, std::map<std::string, dynd::ndt::type> &DYND_UNUSED(tp_vars)) const
20+
{
21+
return candidate_tp.get_id() == m_id;
22+
}
23+
1924
bool operator==(const base_type &rhs) const;
2025
};
2126

0 commit comments

Comments
 (0)