gritzko / swarm

JavaScript replicated model (M of MVC) library
http://swarmdb.net/
MIT License
2.68k stars 97 forks source link

Maybe wrong Op.toString() result #104

Open volyx opened 6 years ago

volyx commented 6 years ago

In JS

test('test', () => {
    let f = new Frame('*rga#test@2:1!:0\'B\'');
    for (const op of f) {
        console.log(op.toString());
    }
});

JS result

    *rga#test@2:1!
    *rga#test@2:$'B',

In Go

func Test_simpleOp(t *testing.T) {
  frame := ron.ParseFrame([]byte("*rga#test@2:1!:0'B'"))
  for !frame.EOF() {
    fmt.Println(frame.OpString());
    frame.Next();
  }
}

Go result

*rga#test@2:1!
*rga#test@2'B',

@olebedev @gritzko