code: function parseElements(compound, allowDecimal) {
    let elementGroups = compound.match(elementGroupRegex)
  
    return elementGroups.reduce((accu, elem) => {
      let count = '1'
      let atom = elem
  
      if (numericPortionRegex.test(elem)) {
        count = elem.match(numericPortionRegex)[0]
        atom = elem.replace(numericPortionRegex, '')
      }
  
      return [...accu, {atom, count}]
    }, [])
  }
docs: private