This ended up being easiest with a runtime function. I couldn't push this
into the standard library because the standard library doesn't know about
NSObject, and I couldn't compile the ObjectiveC module as -parse-stdlib
because it uses standard library types and doesn't otherwise know how to
find the "swift" module.
Swift SVN r7581
Make sure that all assigns are lowered by the memory promotion pass, even those
that don't refer to a box. These are always assignments, not initializations.
Swift SVN r7543
to being a semantic assign. The functional difference here is only
for unowned pointers, where now the conversion from strong to unowned
is implicit in the assign.
The logic behind this is that 'assign' is really part of SILGen, that
is only moved later to make it easier to make it be flow sensitive.
Since it is part of SILGen and will be using some of the type lowering
functionality used by SILGen, we should play by its rules.
No functionality change.
Swift SVN r7507
...rather than as a separate step. This avoids duplicating Parse and Sema
work for these. (This is the new and correct version of r7377.)
Also, remove leftover code for building "swift.swift" and friends in lieu
of proper modules. We're not going back to those days. :-)
Swift SVN r7420
It's used for class-bounded protocols, not just Foundation objects.
No test because I couldn't figure out how to write a non-compilation test.
Swift SVN r7367
We haven't fully updated references to union cases, and enums still are not
their own thing yet, but "oneof" is gone. Long live "union"!
Swift SVN r6783
This creates a regression in REPL printing for class instances, which now will print the mangled class name of the instance, since Object.className was using the Swift demangler to demangle the type name. REPL printing is getting an overhaul so I think this is OK for now.
Swift SVN r6704
This commit merges EnvironmentVariables and CommandLineArguments into a single
swift.Process global variable. POSIX-dependent parts are available as
extension with "import POSIX".
Original message:
stdlib: split the Process class into a POSIX-dependent (EnvironmentVariables)
and POSIX-independent (CommandLineArguments) parts
Swift SVN r6331
This adds builtin types Builtin.VecNxT, where N is a natural number
and T is a builtin type, which map down to the LLVM type <N x T>.
Update varous builtins to support vector arguments, e.g., binary
operations, comparisons, negation. Add InsertElement and
ExtractElement builtins for vectors.
On top of these builtins, add Vec4f and Vec4b structs to the standard
library, which provide 4xFloat and 4xBool vectors, respectively, with
basic support for arithmetic. These are mostly straw men, to be burned
down at our leisure.
Some issues as yet unresolved:
- Comparisons of Vec4f'ss are producing bogus Vec4b's, which I
haven't tracked down yet.
- We still don't support the shuffle builtin, although it should be
easy
- More testing!
Swift SVN r5820