• Robert Griesemer's avatar
    go/printer: idempotent comment formatting · 241b2360
    Robert Griesemer authored
    Also:
    
    - Refactored testing framework to permit easier
    idempotency testing.
    
    - Applied gofmt -w src misc
    
    This CL depends on CL 6639044 being applied first.
    
    Formatting is not idempotent for all files: In those
    files the comment position has changed (due to missing
    precise location information) and/or the comment formatting
    cannot/is not aware of independent code re-formatting.
    In general it is very hard to make format idempotent when
    running it in one pass only. Leaving that aside for now.
    
    Fixes #1835.
    
    R=r, rsc
    CC=golang-dev
    https://golang.org/cl/6624051
    241b2360
printer.go 35 KB