Advertisment

On Wednesday, a developer called Tendo Pein announced the launch of a new smart contract programming language for the Bitcoin Cash network. Pein said “Spedn,” a BCH-based language, is designed for explicitness and safety while having a syntax similar to the C programming environment.

Also read: BCH Devcon Streamlines Bitcoin Innovation in San Francisco 

High-Level BCH Smart Contracts

Meet 'Spedn' — A Smart Contract Programming Language for Bitcoin Cash

Bitcoin Cash proponents have been introduced to a new smart contract programming language specifically designed for the BCH protocol. The developer Tendo Pein has explained in a recent blog post that one of the difficulties of programming smart contracts with Bitcoin is due to the Script language. Pein said Bitcoin’s Script is a stack-oriented language, similar to the Forth programming language and environment. But instead of giving up, Pein’s passion for the Haskell data processing syntax led the developer to start building Spedn.

“Today, I’m pleased to announce Spedn — A high-level smart contract language for Bitcoin Cash,” Pein declared in his post. “It is designed for explicitness and safety, statically typed and detects many errors at compile time, explicitly typed with no guessing to what the expression is supposed to return. It is purely functional — free of side effects, the common source of bugs, and it has a familiar C-like syntax.”

Meet 'Spedn' — A Smart Contract Programming Language for Bitcoin Cash
Spedn specifications.

A Syntax Overview and
Two Smart Contract Examples

Spedn’s documentation is available for BCH developers to review and provide feedback. The specifications give a syntax overview, contract templates, lexical scopes, and more. Additionally, Pein’s work details math functions, hashing functions, cryptographic checks, and the command line interface for compiling. The Spedn documentation further gives developers a quick-start guide and a write-up on understanding Bitcoin Script.

The specifications of Pein’s smart contract language also show examples of using it for zero-confirmation forfeits, a contract based on a proposal by BCH developer Awemany to secure zero-confirmation transactions. Another Spedn example is the Chainbet protocol, which was originally created by Jonald Fyookball. Chainbet is a BCH protocol that enables onchain betting in a decentralized manner. In Pein’s example, the developer said, “the flow of the bet consists of several steps that can be expressed in Spedn.”

Meet 'Spedn' — A Smart Contract Programming Language for Bitcoin Cash
Jonald Fyookball’s Chainbet protocol expressed in the Spedn language

Similar to the Ethereum network’s Solidity programming language, the Bitcoin Cash protocol now has a coding language that developers can work with that is specifically designed for BCH-based smart contracts. But the creator of Spedn emphasized that the project is still in its infancy as far as development is concerned.

“Many breaking changes may come and it’s far from being an “out of the box” solution for smart contracts developers,” Pein added. The programmer is looking for contributors who can offer syntax ideas, code review, unit tests, and bug reports.

What do you think about the Spedn programming language? Let us know your thoughts about this subject in the comments section below.  


Images via Shutterstock, Spedn, Twitter, and Pixabay. 


At news.Bitcoin.com all comments containing links are automatically held up for moderation in the Disqus system. That means an editor has to take a look at the comment to approve it. This is due to the many, repetitive, spam and scam links people post under our articles. We do not censor any comment content based on politics or personal opinions. So, please be patient. Your comment will be published.

The post Meet ‘Spedn’ — A Smart Contract Programming Language for Bitcoin Cash appeared first on Bitcoin News.

Get the latest Bitcoin News on The Bitcoin News
Our Social Networks:
Facebook Instagram Pinterest Reddit Telegram Twitter Youtube