def end_document implicit_end = !streaming?
      @last.implicit_end = implicit_end
      n = pop
      set_end_location(n)
      n
    end
def end_document implicit_end = !streaming?
      @last.implicit_end = implicit_end
      n = pop
      set_end_location(n)
      n
    end
Handles end_document events with +version+, +tag_directives+,
 and +implicit+ styling.

 See Psych::Handler#start_document