[swift-dev] Fwd: [swift-users] hasSuffix(_:) and .hasPrefix(_:) String methods missing on Linux

2015-12-11 Thread Alex Blewitt via swift-dev
There’s a FIXME and a radar (18878343) in the source for StringLegacy: https://github.com/apple/swift/blob/master/stdlib/public/core/StringLegacy.swift#L98 Can the information be re-created as a SwiftBug instead? Alex > Begin forwarded message: > > From: Alex Blewitt > Subject: Re: [swift-us

[swift-dev] Implementing hasPrefix and hasSuffix

2015-12-22 Thread Alex Blewitt via swift-dev
I raised https://bugs.swift.org/browse/SR-337 to implement hasPrefix and hasSuffix in Swift (instead of depending on the Objective-C implementation and only being available for OSX at present. I have an implementation which I’d like to create a pull reques

Re: [swift-dev] long double usage in swift

2016-03-23 Thread Alex Blewitt via swift-dev
There’s a Float80 type, if you’re looking for an 80-bit floating point value. Alex > On 23 Mar 2016, at 21:25, Saleem Abdulrasool via swift-dev > wrote: > > Hi, > > I was looking at an ABI related issue on Windows. In trying to construct a > test case, it seems that I am unable to import a

Re: [swift-dev] long double usage in swift

2016-03-23 Thread Alex Blewitt via swift-dev
Why not? https://github.com/apple/swift/blob/8d9ef80304d7b36e13619ea50e6e76f3ec9221ba/test/Inputs/clang-importer-sdk/usr/include/ctypes.h#L146 > On 23 Mar 2016, at 21:29, Saleem Abdulrasool wrote: > > On Wed, Mar 23, 2016 at 2:28 PM, Alex Blewitt > wrote: > There

Re: [swift-dev] SIL Inspector

2016-04-13 Thread Alex Blewitt via swift-dev
The presentation I gave at QCon London 2016 where I talked about SIL Inspector has now been published on InfoQ: http://www.infoq.com/presentations/swift-open-source Alex > On 4 Dec 2015, at 13:27, Alex Blewitt wrote: > > I wrote a small utility SILInspector [1] (which wraps around the output

[swift-dev] VS Code language protocol

2016-06-08 Thread Alex Blewitt via swift-dev
There is an increasing number of languages and IDEs supporting VS Code’s language agnostic server protocol. https://github.com/Microsoft/vscode-languageserver-protocol/wiki/Protocol-Implementations Alex ___ swift-dev mailing list swift-dev@swift.org ht

[swift-dev] Swiftc and -parse-sil?

2016-10-18 Thread Alex Blewitt via swift-dev
The swift compiler has an option '-parse-sil' which could previously be used to parse SIL code. However, it looks like the swift compiler is assuming it's still Swift code: $ echo "sil_stage canonical" | xcrun swiftc -parse-sil - :1:10: error: consecutive statements on a line must be separated

Re: [swift-dev] Swiftc and -parse-sil?

2016-10-18 Thread Alex Blewitt via swift-dev
> On 18 Oct 2016, at 14:58, Mark Lacey wrote: > > >> On Oct 18, 2016, at 3:43 AM, Alex Blewitt via swift-dev > <mailto:swift-dev@swift.org>> wrote: >> >> The swift compiler has an option '-parse-sil' which could previously be used >&

[swift-dev] Cleaning up stale branches?

2016-10-21 Thread Alex Blewitt via swift-dev
There are a lot of branches in the main Swift Git repository at the moment. Many of these appear to be short-term testing branches that are out of date, or work in progress that may be better in an external repository until the work is done. There are also a number of branches (e.g. swift-3.0-pr

[swift-dev] Autoconf needed for builds?

2016-11-15 Thread Alex Blewitt via swift-dev
I just tried to build Swift on Ubuntu 10.04 and it failed with an error message 'autoreconf: command not found'. It seems this comes with the autoconf module. According to https://github.com/apple/swift/#system-requirements the requirements f

Re: [swift-dev] Autoconf needed for builds?

2016-11-16 Thread Alex Blewitt via swift-dev
ps://github.com/apple/swift-corelibs-libdispatch/blob/master/INSTALL.md#building-and-installing-for-linux> > > Thanks, > Mishal Shah > > Mishal Shah > > On Tue, Nov 15, 2016 at 8:31 AM, Alex Blewitt via swift-dev > mailto:swift-dev@swift.org>> wrote: > I jus

[swift-dev] Automatically building SourceKit on Linux

2016-11-22 Thread Alex Blewitt via swift-dev
I have created a few pull requests regarding SourceKit support on Linux: https://github.com/apple/swift/pull/5861 - Update documentation for building on Linux https://github.com/apple/swift/pull/5862 - Allow S

Re: [swift-dev] Automatically building SourceKit on Linux

2016-12-01 Thread Alex Blewitt via swift-dev
cy in this way, or is there a preferred alternative? If the solution in 5903 is the right way of doing it, what else needs to be passed out to the recursive make call? Alex > On 22 Nov 2016, at 18:05, Alex Blewitt via swift-dev > wrote: > > I have created a few pull req

Re: [swift-dev] [swift-build-dev] Reverting c85cbe

2017-01-17 Thread Alex Blewitt via swift-dev
Have created https://github.com/apple/swift/pull/6852 if that's easier to merge. Alex > On 17 Jan 2017, at 09:42, Ankit Aggarwal wrote: > > + swift-dev > > >> On 17-Jan-2017, at 2:58 PM, Alex Blewitt via swift-build-dev >> mailto:swift-build-...@sw

Re: [swift-dev] Reduce app startup time by combining swift-libs

2017-02-20 Thread Alex Blewitt via swift-dev
> On 17 Feb 2017, at 21:58, Michel Loenngren via swift-dev > wrote: > > All, > > When starting an app that includes swift these libs are being loaded: > > libswiftCoreGraphics.dylib > libswiftDispatch.dylib > libswiftObjectiveC.dylib > libswiftCore.dylib > libswiftDarwin.dylib > libswift

Re: [swift-dev] Integrating SourceKit into ubuntu

2017-02-21 Thread Alex Blewitt via swift-dev
> On 20 Feb 2017, at 23:04, Félix Fischer via swift-dev > wrote: > > How much of it is possible? I want to make a plugin for autocompletion and > syntax highlighting that is cross-platform too. The sourcekit library now builds in a single pass on Linux when the dispatch libraries are availab

Re: [swift-dev] compilation error in lldb

2017-02-21 Thread Alex Blewitt via swift-dev
I mentioned in an earlier mail today to swift-users that the swift-lldb seems to be broken on master on Linux. The only reason that it's passing at the moment is that the other builds are using stable, rather than master, for the swift-lldb checkout. https://lists.swift.org/pipermail/swift-user

Re: [swift-dev] statically embedding the swift repl + sandboxing

2017-03-01 Thread Alex Blewitt via swift-dev
> On 1 Mar 2017, at 16:54, Jason E. Aten via swift-dev > wrote: > > I'm curious if the swift repl has hooks for embedding and sandboxing. > > I'd like to statically compile the swift repl, link it into other code, and > then disable write access to the filesystem, for example. > > Could someo

Re: [swift-dev] Building swift-3.1-branch from source

2017-04-25 Thread Alex Blewitt via swift-dev
You can use ./swift/utils/update-checkout --scheme swift-3.1-branch which will switch the branches to the right place for you. Some of the git repositories aren't necessarily the same; using the update-checkout script to select the right ones will be more successful. You can also use --reset-to-

Re: [swift-dev] Build on s390x error for swift-4.0-branch

2017-07-17 Thread Alex Blewitt via swift-dev
> On 17 Jul 2017, at 14:00, Sam Ding via swift-dev wrote: > > Hi, > > I am trying to build swift-4.0-branch on s390x. > > 1) The 1st error is in stdlib/public/core/UTF8.swift, line 51, > failed at " _sanityCheck(source.count ==4 ) ". > In fact, the test shows "source.count" = "0" on s390x, N

Re: [swift-dev] [swift-users] Swift linux repl can't import

2017-07-27 Thread Alex Blewitt via swift-dev
For the mail (so it's easier to find than in a bug tracking system) the fix is to specify the clang include headers either with an -I on the swift invocation command line, or via the variables C_INCLUDE_PATH and CPLUS_INCLUDE_PATH setting the C_INCLUDE_PATH and CPLUS_INCLUDE_PATH environment var

Re: [swift-dev] how much of non-Swift in Swif

2017-09-06 Thread Alex Blewitt via swift-dev
> On 6 Sep 2017, at 10:26, blaster_in_black via swift-dev > wrote: > > 1) How much and what types of interfaces with non-Swift code is there in the > standard library and the runtime? I have seen references to the "Builtin" > class, that as I understand is directly implemented in LLVM IR langu

Re: [swift-dev] how much of non-Swift in Swif

2017-09-06 Thread Alex Blewitt via swift-dev
> On 6 Sep 2017, at 11:29, blaster_in_black via swift-dev > wrote: > > Hi, Alex, and thank you so much for such a throroughly reply! > > Abusing your good will, let me ask you yet another question. I understand, as > you've pointed out, that certain parts of functionality shall always be > im

Re: [swift-dev] build-script has newfound interest in ninja source?

2017-09-14 Thread Alex Blewitt via swift-dev
Are you passing the path to the existing ninja binary when building? ninja-bin "" "the path to Ninja tool" If not, it will likely try and build ninja for you. if ninja_required and toolchain.ninja is None: args.build_ninja = True Alex > On

Re: [swift-dev] [stdlib] Error recovery hook #12025

2017-09-21 Thread Alex Blewitt via swift-dev
One of the key reasons why you would want to handle those situations is that you may have a leak or other resources, but you may also be handling 99,999 other requests at the same time that you don't want to drop on the floor. Even if you put the server into some kind of degraded mode (for examp

Re: [swift-dev] Failure: Swift master branch build failing on x86 (Ubuntu 16.04).

2017-10-06 Thread Alex Blewitt via swift-dev
> On 6 Oct 2017, at 12:42, Atul Sowani via swift-dev > wrote: > > Hi, > > Swift "master" branch is failing to build on x86 running Ubuntu 16,04 with > following error. Most of the recent builds appear to be working: https://ci.swift.org/view/swift-master-next/job/oss-swift-incremental-RA-l

Re: [swift-dev] Debugger (lldb or gdb) does not show variable value in swift code

2017-10-07 Thread Alex Blewitt via swift-dev
Do you see the same issue if you build from master? Alex > On 7 Oct 2017, at 00:30, Sam Ding via swift-dev wrote: > > Hi, > > I build swift compiler (v4.0) with debug mode ("-d"), however when debugging > compiler swift code, it can not > show the variable value. Here is an example: > frame #

[swift-dev] Remove makefile build?

2017-10-10 Thread Alex Blewitt via swift-dev
According to a recent discussion, there are problems building with the makefile build of Swift: https://lists.swift.org/pipermail/swift-dev/Week-of-Mon-20171009/005561.html Give that, should we consider removing the

[swift-dev] Problems with dispatch?

2017-10-11 Thread Alex Blewitt via swift-dev
On a recent test build there were compile errors with libdispatch, even after a clean build: src/libdispatch.so: error: undefined reference to '__atomic_fetch_sub_4' src/libdispatch.so: error: undefined reference to '__atomic_load_4' src/libdispatch.so: error: undefined reference to '__atomic_fet

Re: [swift-dev] Problems with dispatch?

2017-10-13 Thread Alex Blewitt via swift-dev
> On 11 Oct 2017, at 22:03, Alex Blewitt via swift-dev > wrote: > > On a recent test build there were compile errors with libdispatch, even after > a clean build: > > src/libdispatch.so: error: undefined reference to '__atomic_fetch_sub_4' > src/libdispatch

Re: [swift-dev] Failed to launch REPL process

2017-10-24 Thread Alex Blewitt via swift-dev
> On 24 Oct 2017, at 17:00, Ron Olson via swift-dev wrote: > > Hi all- > > I am able to build Swift 4 on Fedora 26 Linux > (https://github.com/tachoknight/swift-rpm) and while it can compile and run > Swift code just fine, the REPL does not start because of: > > error: failed to launch REPL p

Re: [swift-dev] Failed to launch REPL process

2017-10-24 Thread Alex Blewitt via swift-dev
> On 24 Oct 2017, at 18:19, Ron Olson wrote: > > Hi Alex- > > Thanks for the info, but this isn't in a Docker container, just a regular > Linux VM. Ah, sorry - my bad. I saw Docker in the message with the problem and didn't see the 'not' ;-) > As an additional bit of info, I ran the build sc

Re: [swift-dev] Exact commits of swift releases

2017-11-09 Thread Alex Blewitt via swift-dev
The swift 4.0.2 release tag is available, across the various repositories: https://github.com/apple/swift/releases/tag/swift-4.0.2-RELEASE I believe that the GitHub search does not necessarily find all tags when there are many of

Re: [swift-dev] Building a swift release

2017-11-16 Thread Alex Blewitt via swift-dev
> On 16 Nov 2017, at 14:30, Geordie J via swift-dev wrote: > > Hello, > > I recently asked about building a particular Swift release and couldn’t find > the correct tag. It turns out there are two issues with this: > > 1. Somehow "git checkout swift-4.0.2-RELEASE” doesn’t work. In fact, the >