cl todo: _testnext/type-args-template-recv-mthd#2773
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new test case type-args-template-recv-mthd in cl/_testnext that demonstrates a method call on a template receiver with type arguments. It also adds a disabled test function _TestTestnext in cl/compile_testdir_test.go to run this test case. There are no review comments, and I have no additional feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2773 +/- ##
=======================================
Coverage 94.11% 94.11%
=======================================
Files 32 32
Lines 10147 10147
=======================================
Hits 9550 9550
Misses 427 427
Partials 170 170 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
This PR adds a compile-only test fixture for the template-receiver-method feature and intentionally disables the test runner until the feature is implemented. The change is low-risk and consistent with the project's _TestTestjs precedent.
Two minor observations:
Indentation inconsistency in in.xgo — typeargs.App on line 4 is indented with 4 spaces, while the app.onCall lambda body uses a tab. Go/XGo convention is tabs throughout; normalising line 4 would keep the fixture consistent.
Missing out.go — When out.go is absent cltest.FromDir silently skips the codegen-diff assertion and only verifies compilation. This is acceptable for a todo placeholder, but when the feature lands and _TestTestnext is re-enabled, an out.go should be added so the test actually asserts correct output.
| import "github.com/goplus/xgo/cl/internal/typeargs" | ||
|
|
||
| type MyApp struct { | ||
| typeargs.App |
There was a problem hiding this comment.
This line is indented with 4 spaces while the echo "onCall" body on line 13 uses a tab. Go/XGo convention is tabs throughout — consider normalising to a tab here for consistency.
#2769