mirror of
https://github.com/golang/go
synced 2024-11-19 02:14:43 -07:00
94c387c610
The implementation follows the basic pattern of an indirect function call (genDynamicCall). We use the same trick as SetFinalizer so that direct calls to (r.V).Call, which are overwhelmingly the norm, are inlined. Bug fix (and simplification): calling untag() to unbox a reflect.Value is wrong for reflect.Values containing interfaces (rare). Now, we call untag for concrete types and typeFilter for interface types, and we can use this pattern in all cases. It corresponds to the ssa.TypeAssert operator, so we call it typeAssert. Added tests to cover this. We also specialize reflect.{In,Out} when the operand is an int literal. + Tests. Also: - make taggedValue() panic, not return nil, eliminating many checks. We call isTaggedValue for the one place that cares. - pointer_test: recover from panics in Analyze() and dump the log. R=crawshaw CC=golang-dev https://golang.org/cl/14426050 |
||
---|---|---|
.. | ||
testdata | ||
analysis.go | ||
api.go | ||
callgraph.go | ||
doc.go | ||
example_test.go | ||
gen.go | ||
intrinsics.go | ||
labels.go | ||
pointer_test.go | ||
print.go | ||
reflect.go | ||
solve.go | ||
TODO | ||
util.go |