User Activity

  • Modified a comment on discussion General Discussion on cppbison

    Optional grammar fragments can be a problem too. If you want to try using optional syntax, use google to search for that. I advise against it. Instead of thinking in terms of optional syntax fragments, instead think of two different fragments -- one with the seemingly optional part, and one without. The problem with optional fragments is that they seem to be magnets for bison errors. For example, a source module may or may not define any grammar fragments -- it might be empty or only comments. You...

  • Posted a comment on discussion General Discussion on cppbison

    Optional grammar fragments can be a problem too. Instead of thinking in terms of optional syntax fragments, instead thing of two different fragments -- one with the seemingly optional part, and one without. The problem with optional fragments is that they seem to be magnets for bsion errors. I try to reserve optional syntax for the one case it has to exist: An empty source file should be allowed, so you have a top level, module level grammar fragment that either has definitions in it or it does....

  • Posted a comment on discussion General Discussion on cppbison

    More good advice: don't duplicate syntax fragments textually -- instead make a grammar fragment and use it instead of the duplication. This doesn't prevent all painful debug sessions with bison error messages, but it does reduce them quite a bit. For example, don't do this: target: OPEN_PAREN FRED CLOSE_PAREN other stuff; second: OPEN_PAREN FRED CLOSE_PAREN even more stuff; I'm not positive this exact text will get you into trouble, but you get the idea: duplicating fragments will ultimately burn...

  • Posted a comment on discussion General Discussion on cppbison

    By the way, as bison runs, it writes several kinds of diagnostic information to the file, mc_parser.all. Please use google to find out what it all means. However, it does provide the raw data needed to think through most problems. However, if you make many changes at once, that process may be extremely painful.

  • Posted a comment on discussion General Discussion on cppbison

    Please address Makefile questions in this topic. Note that you can add new source files (.cpp and .h) to the directory without modifying the Makefile. They will be picked up automatically and dependencies will be created for them automatically. Note that this Makefile is meant only to build a single program from all the source in the directory -- so don't try to add a second program or a library to it -- unless you want to take on the challenge of keepign the automatic behaviors working correctly....

  • Posted a comment on discussion General Discussion on cppbison

    Understanding problems in a bison grammar can be challenging. The best advice I can give is to move slowly. That is, do not type in a bunch of grammar changes then expect to debug what is wrong with them. Instead, plan out the changes, then enter them into the grammar file one at a time, fully test all the language fragments your change is supposed to address. Run all your tests. Save the state the whole directory using "make backup", then add the next grammar fragment.

  • Posted a comment on discussion General Discussion on cppbison

    Althought I didn't create the basic mechanism for this solution, I can answer some questions about how to do things and would be happy to, given time limitations, in the forum. Google provides a lot of good examples on how to do things with flex and bison. Unfortunately, you may have to read more than the first search result to find what you are looking for. Good luck.

  • Created ticket #6 on Win-Brash

    visual studio 2017 compile error in scriptLineStream.cxx

View All

Personal Data

Username:
lowellboggs
Joined:
2002-07-04 18:23:50

Projects

This is a list of open source software projects that Lowell Boggs, Jr. is associated with:

Personal Tools