Dmitry Petrov
9db3440e72
Fix type inference issues for 'if' and 'when'.
...
Use 'expectedType' (when present) as an explicit type argument for a special construct call.
Unfortunately, this approach can't be used for elvis due to other elvis-related inference hacks.
Fixes KT-10807, KT-10811.
This also affects KT-6189: now we can infer proper type for 'if'.
If type inference for special call failed, and we found no type errors in sub-expressions,
report TYPE_INFERENCE_FAILED_ON_SPECIAL_CONSTRUCT error.
This (and the hack above) fixes KT-10809: code no longer compiles.
2016-01-27 17:07:20 +03:00
..
2015-10-19 20:45:01 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-12-26 10:46:35 +03:00
2015-12-11 11:11:42 +03:00
2015-09-08 02:04:32 +03:00
2015-11-25 15:39:23 +03:00
2015-11-25 15:39:23 +03:00
2015-12-11 11:11:42 +03:00
2015-11-25 18:26:08 +03:00
2015-12-11 11:11:42 +03:00
2015-09-08 02:04:32 +03:00
2015-12-11 11:11:42 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-12-26 10:46:11 +03:00
2015-12-26 10:46:01 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:35 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:35 +03:00
2015-12-26 10:46:01 +03:00
2015-12-26 10:46:35 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:11 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:11 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:11 +03:00
2015-12-26 10:46:01 +03:00
2015-12-26 10:46:35 +03:00
2015-12-26 10:46:01 +03:00
2015-12-26 10:46:35 +03:00
2015-12-26 10:46:01 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-09-08 02:04:32 +03:00
2015-12-11 11:11:42 +03:00
2015-10-14 20:39:35 +03:00
2015-09-08 02:04:32 +03:00
2016-01-22 10:41:55 +03:00
2016-01-22 10:41:55 +03:00
2016-01-22 10:41:55 +03:00
2016-01-22 10:41:55 +03:00
2016-01-22 10:41:55 +03:00
2016-01-22 10:41:55 +03:00
2016-01-27 17:07:20 +03:00
2016-01-27 17:07:20 +03:00
2016-01-27 17:07:20 +03:00
2016-01-27 17:07:20 +03:00
2015-12-01 10:36:40 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-12-01 10:36:40 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-09-08 02:04:32 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:35 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-11 11:11:42 +03:00
2015-12-26 10:46:35 +03:00
2015-12-11 11:11:42 +03:00
2015-12-18 21:20:54 +03:00
2015-12-18 21:20:54 +03:00
2015-09-08 02:04:32 +03:00
2016-01-27 17:07:20 +03:00
2016-01-27 17:07:20 +03:00
2016-01-22 10:41:55 +03:00
2016-01-19 16:01:10 +03:00