OLD | NEW |
1 40 columns | | 1 40 columns | |
2 >>> split all chained calls if they don't fit on one line | 2 >>> split all chained calls if they don't fit on one line |
3 compiler.something().something().something(); | 3 compiler.something().something().something(); |
4 <<< | 4 <<< |
5 compiler | 5 compiler |
6 .something() | 6 .something() |
7 .something() | 7 .something() |
8 .something(); | 8 .something(); |
9 >>> do not split chained calls if not needed | 9 >>> do not split chained calls if not needed |
10 compiler.something().something().some(); | 10 compiler.something().something().some(); |
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 .method() | 152 .method() |
153 ..x = 1 | 153 ..x = 1 |
154 ..y = 2; | 154 ..y = 2; |
155 >>> conditional invocation | 155 >>> conditional invocation |
156 object?.method().method()?.method().method(); | 156 object?.method().method()?.method().method(); |
157 <<< | 157 <<< |
158 object | 158 object |
159 ?.method() | 159 ?.method() |
160 .method() | 160 .method() |
161 ?.method() | 161 ?.method() |
162 .method(); | 162 .method(); |
| 163 >>> index in property chain |
| 164 someReceiverObject.property1.property2 |
| 165 .property3[0] |
| 166 .property4 |
| 167 .property5 |
| 168 .property6; |
| 169 <<< |
| 170 someReceiverObject |
| 171 .property1 |
| 172 .property2 |
| 173 .property3[0] |
| 174 .property4 |
| 175 .property5 |
| 176 .property6; |
| 177 >>> chained indexes |
| 178 someReceiverObject.property1.property2 |
| 179 .property3[argument] |
| 180 [argument][argument] |
| 181 .property4 |
| 182 .property5 |
| 183 .property6; |
| 184 <<< |
| 185 someReceiverObject |
| 186 .property1 |
| 187 .property2 |
| 188 .property3[argument][argument] |
| 189 [argument] |
| 190 .property4 |
| 191 .property5 |
| 192 .property6; |
OLD | NEW |