Comments (3)
Code generated for Java will of necessity vary from code generated for Objective-C. The question is does the code generated for Objective-C generate a lexer and parser that correctly parse the grammar. When I ran the combined test, its output matched the expected output.
from antlr3-objc2.0-runtime.
Ah OK, I was under the impression I had to use Java to generate the code. I'll dig through the source and try to figure out how to do the code generation from Xcode. Thanks again for your promptness in getting to these!
from antlr3-objc2.0-runtime.
I wanted to clarify the code generation issue, the grammar is generated from java or ANTLRWorks but the language specifier ObjC must be specified in the grammar file.
"options {
backtrack = true;
memoize = true;
language = ObjC;
output = AST;
ASTLabelType= ANTLRCommonTree;
}"
Like the foregoing example. The code generated for the ObjC runtime will be different than the code generated for the "C" runtime and for the Java runtime. If you want to use ANTLRWorks on your mac, you have to rebuild it with the OBJC runtime stringtemplates. If you are using Java you have to have copied the ObjC stringTemplates folder into the ANTLR folder runtime. Check the README here and the ANTLR website for detailed instructions.
from antlr3-objc2.0-runtime.
Related Issues (14)
- Xcode complaining about getScope and setScope's type HOT 1
- Antlr 3.4, Sparql Grammar & java.lang.ArrayIndexOutOfBoundsException HOT 3
- ANTLR.framework HashMap.m missing numerous interface declarations HOT 3
- Files missing from XCode project. HOT 2
- Headers should import Foundation/Foundation.h instead of Cocoa/Cocoa.h HOT 4
- Need help on using ANTLR3 library for Objective-C
- Generated lexers do not include antlr3commontoken.h HOT 2
- dyld problem HOT 5
- About error handling HOT 9
- EXC_BAD_INSTRUCTION HOT 2
- Hardcoded path in ANTLR Project HOT 2
- no such attribute: elementIndex in template context [lexerStringRef] HOT 3
- Linker Ignores Framework HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from antlr3-objc2.0-runtime.