"Lua"의 두 판 사이의 차이
ph
잔글 (→colon vs. dot) |
|||
10번째 줄: | 10번째 줄: | ||
[https://coronalabs.com/blog/2015/12/01/tutorial-understanding-the-colon-vs-dot-operator/ Tutorial: Understanding the colon vs. dot operator] | [https://coronalabs.com/blog/2015/12/01/tutorial-understanding-the-colon-vs-dot-operator/ Tutorial: Understanding the colon vs. dot operator] | ||
− | + | 자신(self)이 필요하면 직접 넘기는 식으로 모두 dot(.)으로 통일할 수 있으나 편의상 다들 <c>:</c>씀. |
2017년 7월 12일 (수) 14:29 기준 최신판
lua 5.3 reference manual
tutorial
- 워낙 문법도 간단해서 레퍼런스 매뉴얼을 대강 다 보는데도 1시간 안쪽이지만, 더욱 간단한 것을 원하면 torch tutorial을 보는 것도 나쁘지 않다.
colon vs. dot
A call v:name(args) is syntactic sugar for v.name(v,args), except that v is evaluated only once.
Lua manual : Function Calls
Tutorial: Understanding the colon vs. dot operator
자신(self)이 필요하면 직접 넘기는 식으로 모두 dot(.)으로 통일할 수 있으나 편의상 다들 :씀.