go lang에서는 {}로 묶을 때 줄 바꿈을 하면 다음과 같은 애러가 나온다.


잘못된 예.

if usersummary.Cloud == "asc" 
 {

       //sqlQuery += " and cloud not like %" + usersummary.Cloud + "%"

 }

users\users.go:4879: missing condition in if statement

users\users.go:4879: usersummary.Cloud == "asc" evaluated but not used

정상적인 예

if usersummary.Cloud == "asc" {
                //sqlQuery += " and cloud not like %" + usersummary.Cloud + "%"

            }


by 무위자연 2015. 6. 19. 12:11
| 1 |