goplus / llgo

A Go compiler based on LLVM in order to better integrate Go with the C ecosystem including Python
Apache License 2.0
365 stars 26 forks source link

ssa: fix wrong reflect type of closure #874

Closed cpunion closed 5 days ago

cpunion commented 6 days ago

Fix https://github.com/goplus/llgo/issues/864 (call closure failed)

Fix https://github.com/goplus/llgo/issues/832 (wrong reflect type of closure):

➜  llgo git:(fix-closure) ✗ go run ./_demo/reflectfunc
func(int, int) int
func
func(int, int) int
func
➜  llgo git:(fix-closure) ✗ go run ./cmd/llgo run ./_demo/reflectfunc
# github.com/goplus/llgo/cmd/llgo
ld: warning: -ld_classic is deprecated and will be removed in a future release
func(...)
func
func(...)
func
codecov[bot] commented 6 days ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 95.53%. Comparing base (e042aad) to head (252f3f0). Report is 5 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #874 +/- ## ======================================= Coverage 95.53% 95.53% ======================================= Files 22 22 Lines 6230 6233 +3 ======================================= + Hits 5952 5955 +3 Misses 246 246 Partials 32 32 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


🚨 Try these New Features: