Home Help Center

Remaking the SLICE parser, ++

catalincatalin Member ✭✭

Ice 1.1.0 on Redhat 9.0:

I am experimenting with the SLICE language and I wonder how can I remake the SLICE parser and the slice2cpp application so that I can try out my new grammars?

Just issuing "make" in the top Ice directory does not work because make does not catch changes in the Grammar.y file. Neither does it work to issue "make" in the SRC/Slice directory.



  • marcmarc FloridaAdministrators, ZeroC Staff Marc LaukienOrganization: ZeroC, Inc.Project: The Internet Communications Engine ZeroC Staff
    In the file config/Make.rules, find the following lines:
    #%.h %.cpp: %.y
    #       rm -f $(*F).h $(*F).cpp
    #       bison $(BISONFLAGS) $<
    #       mv $(*F).tab.c $(*F).cpp
    #       mv $(*F).tab.h $(*F).h
    #       rm -f $(*F).output
    #%.cpp: %.l
    #       flex $(FLEXFLAGS) $<
    #       rm -f [email protected]
    #       echo '#include <IceUtil/Config.h>' > [email protected]
    #       cat lex.yy.c >> [email protected]
    #       rm -f lex.yy.c

    Remove the '#' from the beginning of the lines. Then the Grammer.cpp and Scanner.cpp files are automatically generated when you change the .y/.l files.
Sign In or Register to comment.