Little known developer (dev) Tendo Pein and his project Spedn were boosted this week when Bitcoin Cash (BCH) blockchain entrepreneur and developer Ryan X. Charles Tweeted in praise of the innovation. Described as “A high-level smart contract language” for BCH with a wink toward not making “your brain hurt,” it claims to provide high-level language to be compiled on Script’s virtual machine bytecode.
Also read: Bitcoin Cash Association Funds $1,000 a Month Grant to EatBCH
Spedn Comes Highly Recommended
“It is designed for explicitness and safety,” dev Tendo Pein posted to Medium, detailing Spedn. “It is statically typed — detects many errors at compile time; It is explicitly typed — no guessing what the expression is supposed to return; It is purely-functional — free of side effects, the common source of bugs; It has a familiar C-like syntax.”
Asked if Spedn was “quite similar” to another smart contract language for BCH, Ivy, Pein acknowledged as much. “Indeed. But Spedn also supports local variables, if/else statements and BCH opcodes. Ivy produces smaller scripts though,” Pein answered, noting functions brought back in early summer’s upgrade.
Ryan X. Charles was so impressed he Tweeted, “Awesome work. A high-level language that compiles to Script makes writing sophisticated smart contracts on Bitcoin much easier.” News sites picked up the tip and began running with it. Spedn’s advance might be to enable programs written specifically for BCH. These can in turn instruct the Bitcoin Cash protocol to execute Script programs.
At least one analyst brought a splash of cold water to the party. Finrazor’s Azat S. examined the phenomenon of pushing for smart contracts on the BCH chain. He explained, “A smart contract on Ethereum is an address that has some code associated with it. You can think of a smart contract as a program, a combination of persistent scripts, or a set of instructions for the Ethereum Virtual Machine.”
He goes on to note the Ethereum chain uses Solidity programming language, concluding the Ethereum type of smart contract “is possible because Solidity is Turing-complete, meaning it can express all kinds of logical or arithmetic operations and therefore supports commands like if statements.”
BCH, of course, relies on Script. Azat characterizes addresses on the chain as already “primitive smart contracts that lock your unspent transaction outputs,” worrying how “Script is way less powerful than Solidity and does not support if statements or any other commands that regular programming languages do.” He admits to this probably being a security feature rather than a bug, baked-in purposefully. He’s careful to point out, “Exchanges use Script to create multi-signature Bitcoin addresses.”
An Expectations Game
“When new opcodes were added (or rather re-enabled) in May 2018 hard fork of Bitcoin Cash,” Pein continued, “there was quite an expectation of a smart contract boom. What can we see today, nearly half year later? There were some cool new ideas mostly revolving around token protocols utilizing OP_RETURN to store metadata attached to coins. There’s also ChainBet protocol utilizing OP_MOD to provide cryptographically proven random bets, and recently Forfeits were proposed that use OP_CHECKDATASIG (that is expected to activate in November hardfork) to prove doublesped attempt.”
He ended up finding the innovations “too technical.” Pein further describes grappling with jargon and hype, as he “struggled every time I tried to read some spec or article that proposes a new, clever Bitcoin Cash smart contract.”
Ultimately Pein blamed the complexity of Script for slow innovation on the BCH chain. “This famous, intentionally not Turing-complete, FORTH-like language feels for me almost like one of those esoteric languages made with the sole purpose of making your brain hurt.” Frustrated, and after “reading yet another article with a Script example I didn’t understand, the realization was made. Script is basically a low-level assembly language for Bitcoin Cash virtual machine bytecode and we need some high-level language that can be compiled to it.”
CONTINUE THE SPICE and check out our piping hot YouTube channel. Our podcast, Milk, might help sooth that crypto burn. Follow CoinSpice on Twitter. Join our Telegram feed to make sure you never miss a post. Drop some BCH at the merch shop — we’ve got some spicy shirts for men and women. Don’t forget to help spread the word about CoinSpice on your social media.