Cygwin is considered a distinct target with a distinct ABI, environment
conditions, and data types. Though the goal of the project is
native Windows integration with UNIX-likes, that is not compatible with
the idea that the platform can be ignored as Win-like enough to have the
existing os(Windows) condition apply.
This constant is not imported by the ClangImporter:
#define p_starttime p_un.__p_starttime
Add a shim to do the same thing.
Fixes rdar://problem/31549450
These changes caused a number of issues:
1. No debug info is emitted when a release-debug info compiler is built.
2. OS X deployment target specification is broken.
3. Swift options were broken without any attempt any recreating that
functionality. The specific option in question is --force-optimized-typechecker.
Such refactorings should be done in a fashion that does not break existing
users and use cases.
This reverts commit e6ce2ff388.
This reverts commit e8645f3750.
This reverts commit 89b038ea7e.
This reverts commit 497cac64d9.
This reverts commit 953ad094da.
This reverts commit e096d1c033.
rdar://30549345
This patch splits add_swift_library into two functions one which handles
the simple case of adding a library that is part of the compiler being
built and the second handling the more complicated case of "target"
libraries, which may need to build for one or more targets.
The new add_swift_library is built using llvm_add_library, which re-uses
LLVM's CMake modules. In adapting to use LLVM's modules some of
add_swift_library's named parameters have been removed and
LINK_LIBRARIES has changed to LINK_LIBS, and LLVM_LINK_COMPONENTS
changed to LINK_COMPONENTS.
This patch also cleans up libswiftBasic's handling of UUID library and
headers, and how it interfaces with gyb sources.
add_swift_library also no longer has the FILE_DEPENDS parameter, which
doesn't matter because llvm_add_library's DEPENDS parameter has the same
behavior.
sys/user.h provides definitions for registers. It would previously get
merged into the sys module which could result in it being multiply
included (as in the case of libdispatch). Add an explicit submodule.
Noticed when building libdispatch on Linux AArch64.
- CYGWIN symbol is used to distinguish Cygwin environment from other OS
and other environment in Windows.
- Added windows and windowsCygnus to OSVersion in StdlibUnittest
* Mark several C macros imported from <float.h> as deprecated.
These macros all have straightforward replacements in terms of static properties on FloatingPoint or BinaryFloatingPoint. It is necessary to add 1 in a few places because of differences between how C and Swift count significand bits and normalize the significand, but this is expected to have minimal impact on code in practice (and when it does have impact, using the Swift definition is generally simpler).
* Address review notes from @moiseev.
This fixes <rdar://problem/27871465>
Now that square root is being propoerly inlined and optimized away, it
is safe to deprecate these two constants in favor of a Swiftier API.
Fixes: <rdar://problem/30003973>
* Deprecating M_PI and a few other constants in favor of better API
Deprecating `M_PI`, `M_PI_2`, `M_PI_4`.
Sugesting using `Double.pi` or even just `.pi` to allow type be inferred
and avoid a type-cast.
Fixes: <rdar://problem/26602190>
Clang importer is unable to handle `((void *)-1)`, therefore manually
declaring the said constant in both Darwin and Glibc modules.
rdar://problem/26689135
Things like: PthreadBarriers.swift:114:50: error: cannot convert value of type 'UnsafeMutablePointer<pthread_mutex_t>' (aka 'UnsafeMutablePointer<OpaquePointer>') to expected argument type 'UnsafeMutablePointer<pthread_mutex_t?>' (aka 'UnsafeMutablePointer<Optional<OpaquePointer>>')
on barrier.pointee.mutex . I need to do more research to understand this