SetResult cannot be non-pointer. #475
-
When I run this: func main() {
} case SetResult(result). // len(result) 0 Can result be non-pointer? |
Beta Was this translation helpful? Give feedback.
Answered by
moorereason
Oct 12, 2021
Replies: 1 comment 1 reply
-
If you don't pass a pointer, you're passing a copy of the value to result = res.Result().(*[]AutoGenerated) |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
w570955342
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you don't pass a pointer, you're passing a copy of the value to
SetResult
, so I think you would need to use*Response.Result()
to retrieve the result: