Skip to main content

parse

Function parse 

Source
pub fn parse(input: &str) -> Result<BigSmiles, ParseError>
Expand description

Parse a BigSMILES string into a BigSmiles AST.

BigSMILES extends SMILES with stochastic objects {...} for polymer notation.

ยงExamples

use bigsmiles::parse;

let pe = parse("{[]CC[]}").unwrap();
let ps = parse("{[]CC(c1ccccc1)[]}").unwrap();
let copo = parse("{[$]CC[$],[$]CC(C)[$]}").unwrap();
let pe_end = parse("CC{[$]CC[$]}CC").unwrap();