Re: [swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Nethra Ravindran via swift-corelibs-dev
Thanks Philippe!

- Nethra Ravindran

On Tue, Feb 21, 2017 at 10:44 PM, Philippe Hausler 
wrote:

> The reasoning why is that some classes are designed as a has-a
> relationship instead of an is-a relationship. For example a NSRunLoop has a
> CFRunLoopRef but a NSString is a CFStringRef. This means that you cannot
> pass a NSRunLoop to a function that takes a CFRunLoopRef by design.
> Where-as any method that takes a CFStringRef can take a NSString.
>
> The reasoning for this behavior is to match the behavior of the
> objective-c version of Foundation.
>
> On Feb 21, 2017, at 10:20 AM, Nethra Ravindran via swift-corelibs-dev <
> swift-corelibs-dev@swift.org> wrote:
>
> For example  NSURLComponents is not CFBridgeable.
>
> - Nethra Ravindran
>
> On Tue, Feb 21, 2017 at 3:01 PM, Alex Blewitt  wrote:
>
>> Do you have a couple of examples that you're referring to?
>>
>> Alex
>>
>> On 21 Feb 2017, at 09:25, Nethra Ravindran via swift-corelibs-dev <
>> swift-corelibs-dev@swift.org> wrote:
>>
>> Hi everyone,
>>
>> To be more precise, I would like to know why few classes are not
>> CFBridgeable.
>>
>> Thank you.
>>
>> - Nethra Ravindran
>>
>> On Tue, Feb 21, 2017 at 2:20 PM, Nethra Ravindran <
>> nethraravindra...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> I see that some classes are bridgeable and some are not. It would be
>>> great if someone can explain why few classes are not bridgeable.
>>>
>>> Thank you!
>>>
>>> - Nethra Ravindran
>>>
>>
>> ___
>> swift-corelibs-dev mailing list
>> swift-corelibs-dev@swift.org
>> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev
>>
>>
>>
> ___
> swift-corelibs-dev mailing list
> swift-corelibs-dev@swift.org
> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev
>
>
>
___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


Re: [swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Philippe Hausler via swift-corelibs-dev
The reasoning why is that some classes are designed as a has-a relationship 
instead of an is-a relationship. For example a NSRunLoop has a CFRunLoopRef but 
a NSString is a CFStringRef. This means that you cannot pass a NSRunLoop to a 
function that takes a CFRunLoopRef by design. Where-as any method that takes a 
CFStringRef can take a NSString.

The reasoning for this behavior is to match the behavior of the objective-c 
version of Foundation.

> On Feb 21, 2017, at 10:20 AM, Nethra Ravindran via swift-corelibs-dev 
>  wrote:
> 
> For example  NSURLComponents is not CFBridgeable.
> 
> - Nethra Ravindran
> 
> On Tue, Feb 21, 2017 at 3:01 PM, Alex Blewitt  > wrote:
> Do you have a couple of examples that you're referring to?
> 
> Alex
> 
>> On 21 Feb 2017, at 09:25, Nethra Ravindran via swift-corelibs-dev 
>> mailto:swift-corelibs-dev@swift.org>> wrote:
>> 
>> Hi everyone,
>> 
>> To be more precise, I would like to know why few classes are not 
>> CFBridgeable.
>> 
>> Thank you.
>> 
>> - Nethra Ravindran
>> 
>> On Tue, Feb 21, 2017 at 2:20 PM, Nethra Ravindran 
>> mailto:nethraravindra...@gmail.com>> wrote:
>> Hi,
>> 
>> I see that some classes are bridgeable and some are not. It would be great 
>> if someone can explain why few classes are not bridgeable.
>> 
>> Thank you!
>> 
>> - Nethra Ravindran
>> 
>> ___
>> swift-corelibs-dev mailing list
>> swift-corelibs-dev@swift.org 
>> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev 
>> 
> 
> 
> ___
> swift-corelibs-dev mailing list
> swift-corelibs-dev@swift.org
> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev

___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


Re: [swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Nethra Ravindran via swift-corelibs-dev
For example  NSURLComponents is not CFBridgeable.

- Nethra Ravindran

On Tue, Feb 21, 2017 at 3:01 PM, Alex Blewitt  wrote:

> Do you have a couple of examples that you're referring to?
>
> Alex
>
> On 21 Feb 2017, at 09:25, Nethra Ravindran via swift-corelibs-dev <
> swift-corelibs-dev@swift.org> wrote:
>
> Hi everyone,
>
> To be more precise, I would like to know why few classes are not
> CFBridgeable.
>
> Thank you.
>
> - Nethra Ravindran
>
> On Tue, Feb 21, 2017 at 2:20 PM, Nethra Ravindran <
> nethraravindra...@gmail.com> wrote:
>
>> Hi,
>>
>> I see that some classes are bridgeable and some are not. It would be
>> great if someone can explain why few classes are not bridgeable.
>>
>> Thank you!
>>
>> - Nethra Ravindran
>>
>
> ___
> swift-corelibs-dev mailing list
> swift-corelibs-dev@swift.org
> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev
>
>
>
___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


[swift-corelibs-dev] Memory growth regression in NSMutableData

2017-02-21 Thread Sai Kanduri via swift-corelibs-dev
Hi All,
 
I could see a memory leak when running a simple loop that creates NSMutableData objects and appends to them with swift-3.1-DEVELOPMENT-SNAPSHOT-2017-02-14-a-ubuntu16.10>I have not seen this leak with swift-3.0.2.
 
Following is the Leak Summary from Valgrind :
 
With Swift-3.0.2==18606== LEAK SUMMARY:==18606== definitely lost: 16 bytes in 1 blocks==18606== indirectly lost: 20 bytes in 1 blocks==18606== possibly lost: 0 bytes in 0 blocks==18606== still reachable: 74,893 bytes in 10 blocks==18606== suppressed: 0 bytes in 0 blocks==18606== Rerun with --leak-check=full to see details of leaked memory
Swift 3.1
18411== LEAK SUMMARY:==18411== definitely lost: 247,463,936 bytes in 59 blocks==18411== indirectly lost: 0 bytes in 0 blocks==18411== possibly lost: 171,966,640 bytes in 42 blocks==18411== still reachable: 74,885 bytes in 10 blocks==18411== suppressed: 0 bytes in 0 blocks
https://bugs.swift.org/browse/SR-3966 is the corresponding bug report.
 
Have anyone observed the same ? 
 
-SaiHema
 
 
 

___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


Re: [swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Alex Blewitt via swift-corelibs-dev
Do you have a couple of examples that you're referring to?

Alex

> On 21 Feb 2017, at 09:25, Nethra Ravindran via swift-corelibs-dev 
>  wrote:
> 
> Hi everyone,
> 
> To be more precise, I would like to know why few classes are not CFBridgeable.
> 
> Thank you.
> 
> - Nethra Ravindran
> 
> On Tue, Feb 21, 2017 at 2:20 PM, Nethra Ravindran 
> mailto:nethraravindra...@gmail.com>> wrote:
> Hi,
> 
> I see that some classes are bridgeable and some are not. It would be great if 
> someone can explain why few classes are not bridgeable.
> 
> Thank you!
> 
> - Nethra Ravindran
> 
> ___
> swift-corelibs-dev mailing list
> swift-corelibs-dev@swift.org
> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev

___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


Re: [swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Nethra Ravindran via swift-corelibs-dev
Hi everyone,

To be more precise, I would like to know why few classes are not
CFBridgeable.

Thank you.

- Nethra Ravindran

On Tue, Feb 21, 2017 at 2:20 PM, Nethra Ravindran <
nethraravindra...@gmail.com> wrote:

> Hi,
>
> I see that some classes are bridgeable and some are not. It would be great
> if someone can explain why few classes are not bridgeable.
>
> Thank you!
>
> - Nethra Ravindran
>
___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


[swift-corelibs-dev] Query on bridgeable classes

2017-02-21 Thread Nethra Ravindran via swift-corelibs-dev
Hi,

I see that some classes are bridgeable and some are not. It would be great
if someone can explain why few classes are not bridgeable.

Thank you!

- Nethra Ravindran
___
swift-corelibs-dev mailing list
swift-corelibs-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-corelibs-dev