Coder Social home page Coder Social logo

Comments (4)

clime avatar clime commented on June 9, 2024

However I would really expect the shift rule to be preferred.

Or maybe shift-reduce conflict reported. The way it is caused some really puzzling syntax errors.

from ply.

clime avatar clime commented on June 9, 2024

Any progress here?

from ply.

dabeaz avatar dabeaz commented on June 9, 2024

The precedence of a particular rule is determined by that of the right-most terminal, which in this example is probably the precedence of 'ID'. You probably need to write one of the rules as:

expr : ID WS ID %prec WS

Sorry I missed this issue before---I might have been on travel or away when it was first reported.

from ply.

clime avatar clime commented on June 9, 2024

So I guess that my little hack at yacc.py:~2420:

   # clime: the original code commented out
   #sprec,slevel = Productions[st_actionp[a].number].prec
   #rprec,rlevel = Precedence.get(a,('right',0))
   rprec,rlevel = Productions[st_actionp[a].number].prec
   sprec,slevel = Precedence.get(a,('right',0))

is wrong. The variable assignment seemed somehow the opposite than it should be...

from ply.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.