5 ms·
If t is nil, the function is still called with a nil value for t.
by jamra 10y ago
If t is nil, the function is still called with a nil value for t.
- thewhitetulip 10y agocan we call the method without doing t.F()? like just F()? I accept I have to modify the statement I made.
- chrisbroadfoot 10y agoNo. F refers to a different function than t.F.
- thewhitetulip 10y agoYes that was my point when i said we can't declare functions inside struct We can have methods which work on objects on structs but never a function like class's method