Uploaded image for project: 'yangtools'
  1. yangtools
  2. YANGTOOLS-406

Compilation error: duplicate name for grouping and enum in ietf-routing.yang

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Duplicate
    • None
    • None
    • None
    • None
    • Operating System: All
      Platform: All

    • 2656

    Description

      Hi,

      I tried to generate JAVA class from ietf-routing.yang (see http://www.netconfcentral.org/modules/ietf-routing), but the generated classes cannot compile, because grouping special-next-hop and enum special-next-hop have the same name, yang definition as follows. Could you solve the problem? Thanks!

      grouping special-next-hop {
      description
      "This grouping provides the leaf for specifying special
      next-hop options.";
      leaf special-next-hop {
      type enumeration {
      enum "blackhole"

      { value 0; description "Silently discard the packet."; }

      enum "unreachable"

      { value 1; description "Discard the packet and notify the sender with an error message indicating that the destination host is unreachable."; }

      enum "prohibit"

      { value 2; description "Discard the packet and notify the sender with an error message indicating that the communication is administratively prohibited."; }

      enum "receive"

      { value 3; description "The packet will be received by the local network device."; }

      }
      description
      "Special next-hop options.";
      }
      } // grouping special-next-hop

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              Unassigned Unassigned
              minna.hu@ericsson.com Minna Hu
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: