Swift Command failed due to signal: Segmentation fault: 11 -


here code:

func cache<t: cacheable>(type: int, items: array<t>, options: cacheoptions?) {     log(log_http, "caching ... \(items)")      item: cacheable in items {         let key: string? = item.primarykeyvalue()     } } 

it's pretty simple, cacheable protocol:

public protocol cacheable: class {     func primarykeyvalue() -> string? } 

and compile fails signal issue. if remove :class cacheable, compile go through, when need:

nscache().setobject(item, forkey: "key") 

it complains cacheable not conform anyobject protocol, stuck here. help? thanks.


Comments

Popular posts from this blog

c++ - QTextObjectInterface with Qml TextEdit (QQuickTextEdit) -

javascript - angular ng-required radio button not toggling required off in firefox 33, OK in chrome -

xcode - Swift Playground - Files are not readable -