Integrating Bison/Flex/Yacc into XCode

后端 未结 3 927
粉色の甜心
粉色の甜心 2020-12-13 13:56

Is there a simple way for integrating Bison/Flex/Yacc into XCode?

I want to write my own language to be parsed, which interacts with my ObjC objects.

But the

3条回答
  •  心在旅途
    2020-12-13 14:36

    In a nutshell, give your grammar files a .ym extension instead of .y. Xcode will then run Bison with the necessary magic to support Objective-C.

    Oddly enough, I found this question because I wanted to do the same thing. I remembered a discussion about it on Apple's cocoa-dev mailing list, but this question came up higher in my Google search. I found the discussion I remembered though, on CocoaBuilder - there's a pretty extensive example at the end. I hope it helps both of us, LOL!

    (Edit) Beats the heck out of me how anyone ever managed to find this out, by the way - I still haven't found any official documentation about it.

提交回复
热议问题