Is there a more concise way to specify that the type of an argument is a named tuple? Right now I have a function that takes a named tuple of 2 structs and it makes the declaration very long. For example, if I have declared a struct MyStruct
and I want to declare a function taking a named tuple of MyStruct
it ends up like this:
function my_function(NamedTuple(:A, :B), Tuple{MyStruct, MyStruct}...)
Which seems quite verbose for something that could be just NamedTuple(:A,:B, MyStruct)
.
Is there any way I could shorten it?