golang会在每行自动添加分号,但是如果我觉得一条语句太长了,我想写在两行,那么怎么才能不被自动添加分号呢?
还是举个例子吧:
foo("This is a string test" + "how can i put this string in the second line") //上面那句太长了,我想写成下面这种 foo("This is a string test" + "how can i put the second string like this?")
//但是会被go理解成下面这样(因为自动添加分号),然后就会报错 foo("This is a string test"; + "how can i put the second string like this?");
那,如何写成两行而不报错呢?