[basic.scope.temp] (original) (raw)

Each template-declaration D introduces a template parameter scope that extends from the beginning of its template-parameter-listto the end of the template-declaration.

Any declaration outside the template-parameter-listthat would inhabit that scope instead inhabits the same scope as D.

The parent scope of any scope S that is not a template parameter scope is the smallest scope that contains S and is not a template parameter scope.

[Note 1:

Therefore, only template parameters belong to a template parameter scope, and only template parameter scopes have a template parameter scope as a parent scope.

— _end note_]