Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Ján Kosa via swift-users
I was afraid it will come to that :) I will try to make something tonight, either it will help you fix it, or I will find out what I did wrong On 8 October 2017 at 09:49, Daniel Dunbar wrote: > Is it possible for you to make a small test package that shows the > problem, and file a bug in bugs.s

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Daniel Dunbar via swift-users
Is it possible for you to make a small test package that shows the problem, and file a bug in bugs.swift.org? There may be something we need to fix in SwiftPM before this can work (because of our linking model). - Daniel > On Oct 7, 2017, at 10:42 PM, Ján Kosa via swift-users > wrote: > > T

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Ján Kosa via swift-users
That is exactly what I did. The only package that depends on the protobuf is the PluginInterface. Both MyPlugin and and PluginConsumer depend on the PluginInterface and not on the protobuf itself. I had to shuffle around my dependencies a bit, which resulted in smaller number of dependencies but th

Re: [swift-users] How to check the type of a concrete class that inherits from a generic class?

2017-10-07 Thread Glen Huang via swift-users
I need to do things differently in the shared delegate based on the controller type, so this probably won’t work. But thanks, I believe it will come in handy when I do need to branch on controllers themselves. I do have a question though, since the method is a callback, and its signature is cha

[swift-users] Hacking the swift compiler to use the llvm wasm target

2017-10-07 Thread Fabio Kaminski via swift-users
Hello, I was playing a liitle bit with the Swift compiler to it could use the WebAssembly LLVM backend, the same way Clang already do it right now. Well, i've implemented the toolchain ok, but now its asking me for a Sdk for the new toolchain. My question is: How can i create a new runtime for t

Re: [swift-users] Swift 4.0 LLDBFrontend Crash

2017-10-07 Thread Edward Connell via swift-users
Hi Michael, No I am not evaluating an expression or anything. This all worked fine in past builds. I simply set a breakpoint in a function and after stopping while gathering values for the debugger view, it crashes. It doesn't crash in all functions, but it does crash when trying to stop in many

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
Bizarre. And 10/5 is no longer available for download. $ wget > https://swift.org/builds/development/ubuntu1604/swift-DEVELOPMENT-SNAPSHOT-2017-10-05-a/swift-DEVELOPMENT-SNAPSHOT-2017-10-05-a-ubuntu16.04.tar.gz > --2017-10-07 11:49:56-- > https://swift.org/builds/development/ubuntu1604/swift-DEVEL

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Edward Connell via swift-users
$ find ~/swift -name "*dispatch*" /home/ed/swift/usr/lib/swift/linux/libdispatch.la /home/ed/swift/usr/lib/swift/linux/libdispatch.so /home/ed/swift/usr/lib/swift/dispatch /home/ed/swift/usr/lib/swift/dispatch/dispatch.h On Sat, Oct 7, 2017 at 9:51 AM, Lane Schwartz wrote: > Edward, > > Could y

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
Edward, Could you please try running this command wherever your swift-DEVELOPMENT* directory is located? find swift-DEVELOPMENT-SNAPSHOT-* -name "*dispatch*" Thanks, Lane On Sat, Oct 7, 2017 at 11:47 AM, Edward Connell wrote: > No I installed it yesterday so 10/5 was the current one > > On

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
Strange. 10/5 is not available to download. And the 10/6 release doesn't have libdispatch. On Sat, Oct 7, 2017 at 11:47 AM, Edward Connell wrote: > No I installed it yesterday so 10/5 was the current one > > On Sat, Oct 7, 2017 at 9:36 AM, Lane Schwartz wrote: > >> Do you mean 10/6? I don't see

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Edward Connell via swift-users
No I installed it yesterday so 10/5 was the current one On Sat, Oct 7, 2017 at 9:36 AM, Lane Schwartz wrote: > Do you mean 10/6? I don't see a 10/5 build. > > On Sat, Oct 7, 2017 at 11:26 AM, Edward Connell > wrote: > >> I had the same problem with the 9/30 build, but the 10/5 build worked for

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
This appears in all Ubuntu 16.04 Trunk Development releases currently listed on the Swift downloads page. Bug report is https://bugs.swift.org/browse/SR-6084 I tested the following releases: - 2017-09-22 - 2017-09-23 - 2017-09-24 - 2017-09-25 - 2017-09-26 -

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
Do you mean 10/6? I don't see a 10/5 build. On Sat, Oct 7, 2017 at 11:26 AM, Edward Connell wrote: > I had the same problem with the 9/30 build, but the 10/5 build worked for > me. > > On Sat, Oct 7, 2017 at 9:21 AM, Alex Blewitt via swift-users < > swift-users@swift.org> wrote: > >> This sounds

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Edward Connell via swift-users
I had the same problem with the 9/30 build, but the 10/5 build worked for me. On Sat, Oct 7, 2017 at 9:21 AM, Alex Blewitt via swift-users < swift-users@swift.org> wrote: > This sounds like a bug. There were some changes recently to migrate the > build towards CMake and it may be that they have b

Re: [swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Alex Blewitt via swift-users
This sounds like a bug. There were some changes recently to migrate the build towards CMake and it may be that they have broken the build accordingly. Since I can't find one, can you create a bug at https://bugs.swift.org with the snapshot build that you saw the issue is? Alex > On 7 Oct 2017,

[swift-users] Using libdispatch with Trunk Development snapshot

2017-10-07 Thread Lane Schwartz via swift-users
Hi, I'm on Ubuntu 16, and I'd like to try out the current Trunk Development snapshot. I successfully downloaded and installed it. But when I tried compiling my sample program with it, I got an error that libdispatch wasn't available. I looked in the directory, and sure enough, the development sna

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Geordie Jay via swift-users
Ján Kosa schrieb am Sa. 7. Okt. 2017 um 15:27: > I tried to use @_exported and it helped somewhat. While I still have same > warnings, size of the PluginInterface library went down by 6mb (to 120kb) > so it looks like Protobuf is no longer statically linked to it. However, > size of PluginConsume

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Ján Kosa via swift-users
I tried to use @_exported and it helped somewhat. While I still have same warnings, size of the PluginInterface library went down by 6mb (to 120kb) so it looks like Protobuf is no longer statically linked to it. However, size of PluginConsumer executable went up by same 6mb, it looks like it is lin

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Geordie Jay via swift-users
Ján Kosa schrieb am Sa. 7. Okt. 2017 um 13:34: > I tried swift package clean, but it didn't help > > "Try to ensure the plugin provider module (libA) is (only) being compiled > into its standalone shared library file." > How do I go about this? It is 3rd party module, it doesn't define any > prod

Re: [swift-users] Communicating with dynamically loaded swift library

2017-10-07 Thread Ján Kosa via swift-users
I tried swift package clean, but it didn't help "Try to ensure the plugin provider module (libA) is (only) being compiled into its standalone shared library file." How do I go about this? It is 3rd party module, it doesn't define any products (https://github.com/apple/swift-protobuf.git). Is there

Re: [swift-users] How to check the type of a concrete class that inherits from a generic class?

2017-10-07 Thread Glen Huang via swift-users
Works like a charm, thanks. > On 7 Oct 2017, at 2:56 PM, Slava Pestov wrote: > > You can try upcasting the value to NSObject first, and then performing a > conditional downcast to Controller1 and Controller2. At this point the type > checker will not have enough information to decide that the