Subject: Re: [netmod] Y45 again

From: Ladislav Lhotka <[email-masked]>
Date: Wed, 01 Apr 2015 15:21:41 +0200

Phil Shafer <[email-masked]> writes:

> Ladislav Lhotka writes:
>>BTW, does RFC 6020 forbid importing different revisions of the same
>>module using different prefixes? If not, it might solve this issue.
>
> Sure but if that's the solution, we're in big trouble ;^)
>
> One of the things I learned looking back at the JUNOS DDL files
> while we were working on YANG was that whatever facilities you
> provide, people will use them in ways you never intended; often
> ways you never conceived of, and sometimes ways that turn your
> stomach.  But the BCP for how to handle problems like this shouldn't
> involve multiple imports.

Hopefully it won't be needed that often to use typedefs/grouping from
different revisions in the same module. But if it is needed, this
solution doesn't look that ugly to me:

    import ietf-inet-types {
      revision-date 2013-07-17;
      prefix inet;
    }

    import ietf-inet-types {
      revision-date 2010-09-24;
      prefix inet6021;
    }

The intent is clear, confusion not likely, and no extra syntax is
needed.

Lada

> Thanks,
>  Phil

-- 
Ladislav Lhotka, CZ.NIC Labs
PGP Key ID: E74E8C0C