groue / GRMustache.swift

Flexible Mustache templates for Swift
http://mustache.github.com/
MIT License
597 stars 155 forks source link

Segmentation fault 11 #1

Closed tonybuckingham closed 9 years ago

tonybuckingham commented 9 years ago

App runs fine in simulator and on device, but when archiving for deployment, compiler chokes with Segmentation fault, and the following output:

While emitting IR SIL function @_TTSGSaV16theabsolutesound11MustacheBox_GSaS0Ss14CollectionTypeGVSs17IndexingGeneratorGSaS0GS2_GSaS0_Ss13GeneratorType_S0_S0_S_15MustacheBoxable_SiSiSs16ForwardIndexType_SiSiSs18_SignedIntegerType_SiSiSs33_BuiltinIntegerLiteralConvertible_Si_S0__TF16theabsolutesoundP33_923FE48AD3BF7E753B76F3E22D01634016renderCollectionUSs14CollectionType_USs13GeneratorType_S_15MustacheBoxable_Ss16ForwardIndexType_Ss18_SignedIntegerType_Ss33_BuiltinIntegerLiteralConvertible__FTQ_VS13RenderingInfoGVSs33AutoreleasingUnsafeMutablePointerGSqCSo7NSErrorGSqVS9Rendering for 'renderCollection' at /u/theabsolutesound/theabsolutesound/Mustache/Rendering/MustacheBox.swift:979:9

Seemingly to do with:

private func renderCollection<C: CollectionType where C.Generator.Element: MustacheBoxable, C.Index: BidirectionalIndexType, C.Index.Distance == Int>(collection: C, var info: RenderingInfo, error: NSErrorPointer) -> Rendering? {

Just upgraded to Xcode 6.2, and hadn't ever archived in previous version, so can't say whether this is a bug introduced by 6.2 or not.

Any ideas what might be going on here?

groue commented 9 years ago

Hi Tony,

Yes, I have the issue as well with Xcode 6.2. It looks like the compiler options used when archiving choke on MustacheBox.swift at line 979.

I don't quite know yet what is happening.

groue commented 9 years ago

@tonybuckingham, will you update your master branch, and check again, please?

tonybuckingham commented 9 years ago

Yep, works now . . . thank you!

groue commented 9 years ago

You're welcome Tony. Happy Mustache!