Mixin Name Spaces
Let’s take a look at the mixin name spaces in this lesson.
We'll cover the following
Resolving name ambiguities
It is possible to avoid and resolve name ambiguities in template mixins.
For example, in the following there are two i
variables defined inside main()
: one is defined explicitly in main and the other is mixed in. When a mixed-in name is the same as a name that is in the surrounding scope, then the name that is in the surrounding scope gets used:
Get hands-on with 1400+ tech skills courses.