Этот коммит содержится в:
Ayke van Laethem 2018-08-30 02:36:13 +02:00
родитель 0b372ba5bd
коммит 6e0c60a7a1
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: E97FF5335DFDFDED
2 изменённых файлов: 7 добавлений и 0 удалений

3
ir.go
Просмотреть файл

@ -9,6 +9,9 @@ import (
"golang.org/x/tools/go/ssa" "golang.org/x/tools/go/ssa"
) )
// This file provides a wrapper around go/ssa values and adds extra
// functionality to them.
// View on all functions, types, and globals in a program, with analysis // View on all functions, types, and globals in a program, with analysis
// results. // results.
type Program struct { type Program struct {

Просмотреть файл

@ -5,6 +5,10 @@ import (
"golang.org/x/tools/go/ssa" "golang.org/x/tools/go/ssa"
) )
// This function implements several optimization passes (analysis + transform)
// to optimize code in SSA form before it is compiled to LLVM IR. It is based on
// the IR defined in ir.go.
// Make a readable version of the method signature (including the function name, // Make a readable version of the method signature (including the function name,
// excluding the receiver name). This string is used internally to match // excluding the receiver name). This string is used internally to match
// interfaces and to call the correct method on an interface. Examples: // interfaces and to call the correct method on an interface. Examples: