* (M) pyang/statements.py
- Add a validation phase where changes to types with references
by deviations can be made ahead of validating any reference.
- Remove the `i_leafref` attribute when a deviation changes the
type of a leaf to a type that isn't a leafref.
* (A) test/test_issues/test_i771
- Add a test case validating the fix to issue #771.
Fixes #771.