# Help with error: "N not defined" in method signature but it is

**URL:** <https://discourse.julialang.org/t/help-with-error-n-not-defined-in-method-signature-but-it-is/95226>\
**Category:** General Usage\
**Created:** [February 26, 2023, 3:50pm UTC](https://discourse.julialang.org/t/help-with-error-n-not-defined-in-method-signature-but-it-is/95226 "2023-02-26T15:50:51Z")\
**Posts on this page:** 1\
**Showing post:** 12

<div class="post-metadata">

**Author:** ![uniment](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/uniment/32/24532_2.png) [@uniment](https://discourse.julialang.org/u/uniment)\
**Post date:** [February 26, 2023, 11:59pm UTC](https://discourse.julialang.org/t/help-with-error-n-not-defined-in-method-signature-but-it-is/95226/12 "2023-02-26T23:59:04Z")

</div>

> [@danielwe](#):
>
> What you’re looking for here is `NTuple{<:Any,T}`:

Although this works, this is (strictly speaking) an abuse of the type system: leveraging an undocumented implementation detail that `<:Any` currently simply doesn’t perform any typecheck on type parameters (after all, `3<:Any` throws an error, so it’s nonsensicle that `NTuple{3,Int}<:NTuple{<:Any,Int}` returns `true`). As such, when this loophole eventually gets fixed, your code will break.

See [this recent discussion](https://discourse.julialang.org/t/rfc-add-a-type-called-anytype-thats-subtyped-by-all-other-types-except-any/93956/11) for more.

> [@taotree](#):
>
> and it won’t give an error anymore.

It appears I mistook your intent then: I thought you intended to communicate that the element type of the function’s output tuple is constrained in accordance with the argument’s element type. If not, you could’ve always just written this:

```julia
function test(x::Vector, y)::NTuple
    return (1,2,3)
end

```

---

_[View the full topic](https://discourse.julialang.org/t/help-with-error-n-not-defined-in-method-signature-but-it-is/95226)._
