phylanx
phylanx copied to clipboard
Physl error message for out of bound number of arguments is not precise
For conv1d we have this match data pattern:
hpx::util::make_tuple("conv1d",
std::vector<std::string>{R"(
conv1d(_1, _2_kernel,
__arg(_3_padding, "valid"),
__arg(_4_strides, 1),
__arg(_5_dilation_rate, 1))
)"}
At least 2 arguments should be supplied. The second argument is named, but does not have a default value. Having the following in physl:
conv1d([1,2,3], [1,2,3], "valid", 2, 1, 1, 3)
would result in:
physl: exception caught:
physl.txt(411, 1): attempt to call function 'conv1d' with too many arguments (expected: 1, supplied: 7): HPX(bad_parameter)
The expected number of arguments is 2 not 1 .It would have been more informative if the message was
physl: exception caught:
physl.txt(411, 1): attempt to call function 'conv1d' with too many arguments (expected: 2, allowed: 5, supplied: 7): HPX(bad_parameter)
Good catch!