Confusion: struct directly followed by impl?

I was looking through the standard library, and I stumbled upon this:

struct IsWhitespace impl Fn = |c: char| -> bool {
    c.is_whitespace()
};

I understand that you can use impl to implement functions over a data type, and use impl Trait to implement a trait for a type.

I am having difficulty understanding this. Any help would be appreciated.

Thank you.

This is part of a macro invocation. Macros can take any token sequence, even those that are not valid Rust code, and transform them however they want.

That particular macro is defined here. The language for defining macro matchers is a bit weird, but you should be able to see the same struct name followed by impl in there, and inside the macro you should be able to see separate struct and impl definitions.

I see, thank you.