npm i @cryptoeconomicslab/ovm-compiler
const { Parser, SolidityCodeGenerator, Transpiler } = require('ovm-compiler')
const parser = new Parser()
const generator = new SolidityCodeGenerator()
const compiledPredicates = Transpiler.calculateInteractiveNodes(
parser.parse(
'def ownership(owner) := with Tx(su) as tx { SignedBy(tx, owner) }' +
'def SignedBy(message, owner) := with Bytes() as signature {IsValidSignature(message, owner, signature)}'
)
)
const result = generator.generate(compiledPredicates)
console.log(result)
https://ovm-compiler.netlify.com
npm test
- Plasma checkpoint example
- Plasma exit example
- Plasma ownership predicate example
- Plasma swap predicate example
- Plasma offline swap predicate example
- Plasma fast finality predicate example
- Plasma swap between main chain and Plasma chain predicate example
- State channel example
- Optimistic Rollup example
- add parser
- add byte code generator for ethereum
- add code generator for Substrate
- update language to write state transition