Commit Graph

9 Commits

Author SHA1 Message Date
Zach Panzarino
e3a4147ac9 Update copyright date 2015-12-31 23:28:40 +00:00
practicalswift
8ab8847684 Fix typos. 2015-12-16 22:09:32 +01:00
Jordan Rose
f5b1efb354 Move client-affecting configuration options into a generated Config.h.
This way they can be used from other projects, like LLDB. The downside
is we now have to make sure the header is included consistently in all
the places we care about, but I think in practice that won't be a problem,
especially not with tests.

rdar://problem/22240127

Swift SVN r31173
2015-08-12 17:50:13 +00:00
Jordan Rose
3fcdfd40e9 Remove the "swift/Basic/Optional.h" header.
llvm::Optional lives in "llvm/ADT/Optional.h". Like Clang, we can get
Optional in the 'swift' namespace by including "swift/Basic/LLVM.h".

We're now fully switched over to llvm::Optional!

Swift SVN r22477
2014-10-02 18:51:45 +00:00
Jordan Rose
042569a3be Optional: Replace uses of Nothing with None.
llvm::Optional (like Swift.Optional!) uses None as its placeholder value,
not Nothing.

Swift SVN r22476
2014-10-02 18:51:42 +00:00
Devin Coughlin
0d4e945b3a Construct type refinement context hierarchy in Sema.
This patch adds the beginning of building the type refinement context tree for
availability checking in Sema, guarded by by the
-enable-experimental-availability-checking option. This tree parallels the AST
but is much more sparse: we introduce a new TypeRefinementContext only when
needed. Each context refines the range of potential OS versions that could be
encountered at run time. For the moment, we only refine contexts for function
bodies. I will add refinement contexts for #os(...) in a later commit.

The AST is not directly connected to the TRC tree except at the SourceFile
level; when type checking, we use source locations to look up the TRC
corresponding to an AST element. For the moment, we emit a diagnostic when the
programmer references a potentially unavailable declaration. We will later
change this to treat the declaration as if it had optional type.


Swift SVN r22145
2014-09-19 22:11:29 +00:00
Devin Coughlin
c9d7e6f898 Move AvailabilityAttr::isActivePlatform reasoning to a helper in PlatformKind. NFC.
Swift SVN r21948
2014-09-15 18:21:32 +00:00
Devin Coughlin
5a9ccc5ab2 Add ASTDumper support for AvailabilityQueryExpr
This patch also moves some static utility methods involving PlatformKind out of Attr.h and into PlatformKind.h.


Swift SVN r21896
2014-09-12 00:13:48 +00:00
Devin Coughlin
1b8ed882d3 Move AvailabilityAttr::PlatformKind into its own file
Swift SVN r21728
2014-09-04 23:34:19 +00:00