Ravi Kandhadai
49b0984e19
[Sema][os_log] Allow wrapping os_log strings within constant evaluable functions.
...
As of now, the sema checks for os_log allow only string interpolations to be passed
to the log calls. E.g. logger.log(foo("message")) would not be allowed. This PR
relaxes this requirement and allows it as long as foo is annotated as
@_semantics("constant_evaluable").
<rdar://problem/65215054>
2020-07-15 10:54:08 -07:00
Anthony Latsis
9fd1aa5d59
[NFC] Pre- increment and decrement where possible
2020-06-01 15:39:29 +03:00
Joe Groff
c5863ac0f3
SILOptimizer: Constant fold the _kvcKeyPathString of literal key paths.
...
Eliminate the intermediate key path object when a literal key path is passed to a function that
just wants its KVC string to pass down to an ObjC API.
2020-05-07 13:33:01 -07:00
Ravi Kandhadai
2e0457ab0d
[OSLog Diagnostics] Improve diagnostics emitted in the SIL and Sema diagnostic passes
...
for the os log APIs. These improvements are aimed at covering some rare corner cases.
2020-04-18 15:29:22 -07:00
Ravi Kandhadai
03d726c5c2
[Sema Diagnostics][OSLog] Make the miscellaneous diagnostics that
...
checks the constantness of arguments passed to the new os log APIs
ignore the log level and log object which can be dynamic.
2020-04-17 14:38:13 -07:00
Ravi Kandhadai
b57a1d7c0e
[Sema] Add miscellaneous sema diagnostics to check that the new os log
...
APIs and atomic operations are passed compile-time constants for
certain arguments.
2020-04-06 18:41:13 -07:00