... | @@ -25,9 +25,10 @@ M.f = (M.f, M.f, K.f, \f_22 -> f_22) |
... | @@ -25,9 +25,10 @@ M.f = (M.f, M.f, K.f, \f_22 -> f_22) |
|
|
|
|
|
where all these names are now `Name`s.
|
|
where all these names are now `Name`s.
|
|
|
|
|
|
- The top-level unqualifed `RdrName` "`f`" has become the `External``Name``M.f`.
|
|
|
|
|
|
- The top-level unqualifed `RdrName` "`f`" has become the `External` `Name` `M.f`.
|
|
- The occurrences "`f`" and "`M.f`" are both bound to this `Name`.
|
|
- The occurrences "`f`" and "`M.f`" are both bound to this `Name`.
|
|
- The qualified `RdrName` "`Q.f`" becomes the `Name``K.f`, because the function is defined in module K.
|
|
- The qualified `RdrName` "`Q.f`" becomes the `Name` `K.f`, because the function is defined in module K.
|
|
- The lambda-bound "`f`" becomes an `Internal` name, here written `f_22`. (All the `External` names have uniques too, but we often do not print them.)
|
|
- The lambda-bound "`f`" becomes an `Internal` name, here written `f_22`. (All the `External` names have uniques too, but we often do not print them.)
|
|
|
|
|
|
|
|
|
... | @@ -79,15 +80,19 @@ Here is how to understand these types: |
... | @@ -79,15 +80,19 @@ Here is how to understand these types: |
|
- An `ImpDeclSpec` that describes the entire import declaration. This is shared between all entities brought into scope by a particular import declaration.
|
|
- An `ImpDeclSpec` that describes the entire import declaration. This is shared between all entities brought into scope by a particular import declaration.
|
|
- An `ImpItemSpec` that describes the import item that brought the entity into scope.
|
|
- An `ImpItemSpec` that describes the import item that brought the entity into scope.
|
|
|
|
|
|
|
|
>
|
|
>
|
|
>
|
|
> For example, given
|
|
> For example, given
|
|
>
|
|
>
|
|
|
|
>
|
|
> ```wiki
|
|
> ```wiki
|
|
> import qualified M( x, T(g) ) as Q
|
|
> import qualified M( x, T(g) ) as Q
|
|
> ```
|
|
> ```
|
|
>
|
|
>
|
|
>
|
|
>
|
|
> the `ImpDeclSpec` would describe the `qualified` and `as` part, while the `ImpItemSpec` describes the `T(g)` part. You can look in `RdrName.hs` to see what an `ImportDeclSpec` and `ImpItemSpec` are like!
|
|
> the `ImpDeclSpec` would describe the `qualified` and `as` part, while the `ImpItemSpec` describes the `T(g)` part. You can look in `RdrName.hs` to see what an `ImportDeclSpec` and `ImpItemSpec` are like!
|
|
|
|
>
|
|
|
|
>
|
|
|
|
|
|
- The `Parent` of an entity is the `Name` under which it is grouped when the forms `T(..)` or `T(C,D)` are used in an export or import list. In the `T(..)` form, all the things whose `Parent` is `T` are chosen. In the `T(C,D)` form, it is required that `C` and `D` have `T` as parents.
|
|
- The `Parent` of an entity is the `Name` under which it is grouped when the forms `T(..)` or `T(C,D)` are used in an export or import list. In the `T(..)` form, all the things whose `Parent` is `T` are chosen. In the `T(C,D)` form, it is required that `C` and `D` have `T` as parents.
|
|
For example,
|
|
For example,
|
... | | ... | |