proofpeer / proofpeer-proofscript

The language of ProofPeer: ProofScript
MIT License
8 stars 0 forks source link

Strange parsing in fresh quotes #78

Closed phlegmaticprogrammer closed 8 years ago

phlegmaticprogrammer commented 8 years ago

Apparently the ProofScript interpreter happily executes

let x:'«val ∅»'
let x:'«= ∅»'

which should not even parse.

phlegmaticprogrammer commented 8 years ago

@Chattered I created the following ProofScript file:

theory issue78 extends \root

context
  let x:'«val ∅»'
  let x:'«= ∅»'

and parsing of that theory file comes back with an error as expected. Are you sure it parses for you?

phlegmaticprogrammer commented 8 years ago

Everything seems to work as expected.

phlegmaticprogrammer commented 8 years ago

There is a related bug though that will for example let the following code fail:

  let '«val x»'
  let '«= x»'
phlegmaticprogrammer commented 8 years ago

@Chattered I pushed a fix which should take care of the bug you discovered.