matches.js
function parseObjectPattern (inp) {
    var res = parseKey(inp);
    if (res) {
      if (inp.skipWs().takeAPeek(":")) {
        var patt = parsePattern(inp.skipWs());
        if (patt) return nodeKeyValue(res, patt);
      }
      return nodeKey(res);
    }
  }
function parseObjectPattern (inp) {
    var res = parseKey(inp);
    if (res) {
      if (inp.skipWs().takeAPeek(":")) {
        var patt = parsePattern(inp.skipWs());
        if (patt) return nodeKeyValue(res, patt);
      }
      return nodeKey(res);
    }
  }
function parseObjectPattern ( inp ) { var res = parseKey ( inp ) ; if ( res ) { if ( inp . skipWs ( ) . takeAPeek ( ":" ) ) { var patt = parsePattern ( inp . skipWs ( ) ) ; if ( patt ) return nodeKeyValue ( res , patt ) ; } return nodeKey ( res ) ; } }
Objects can only contain keys or key-value pairs.
Objects can only contain keys or key - value pairs .