• Robert Griesemer's avatar
    cmd/compile: fix exporting of 'for' loops · f125052a
    Robert Griesemer authored
    The existing code for encoding 'for' loops in exported, inlineable
    functions incorrectly assumed that the 'Right' field points to an
    'expression' node. Adjusted the code to be able to handle any kind
    of node. Made matching changes for the binary and indexed exporter.
    
    This only shows up together with other pending compiler changes that
    enable exporting of such functions which contain for loops.
    
    No tests yet because we can't test this w/o those pending compiler
    changes. Once those changes are in, this code will be tested implicitly.
    However, the changes were tested manually together with the patches
    described in the issue.
    
    Fixes #25222.
    
    Change-Id: I54babb87e5d665d2c1ef6116c1de1b8c50b1138e
    Reviewed-on: https://go-review.googlesource.com/119595Reviewed-by: 's avatarDavid Chase <drchase@google.com>
    f125052a
bimport.go 30.4 KB