mirror of
https://github.com/flynx/serialize.js.git
synced 2026-07-10 11:10:57 +00:00
cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
58d09563aa
commit
2c72693d03
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "ig-serialize",
|
"name": "ig-serialize",
|
||||||
"version": "1.3.0",
|
"version": "1.3.1",
|
||||||
"description": "experimental extended json serializaion...",
|
"description": "experimental extended json serializaion...",
|
||||||
"main": "serialize.js",
|
"main": "serialize.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
10
serialize.js
10
serialize.js
@ -54,7 +54,6 @@
|
|||||||
/*********************************************************************/
|
/*********************************************************************/
|
||||||
|
|
||||||
|
|
||||||
var EMPTY = '<empty>'
|
|
||||||
var NULL = 'null'
|
var NULL = 'null'
|
||||||
var UNDEFINED = 'undefined'
|
var UNDEFINED = 'undefined'
|
||||||
var NAN = 'NaN'
|
var NAN = 'NaN'
|
||||||
@ -558,15 +557,6 @@ module.eJSON = {
|
|||||||
initial instanceof Array
|
initial instanceof Array
|
||||||
&& initial.length++
|
&& initial.length++
|
||||||
continue }
|
continue }
|
||||||
if(str.slice(i, i+EMPTY.length) == EMPTY){
|
|
||||||
index++
|
|
||||||
i += EMPTY.length
|
|
||||||
if(str[i] == ','){
|
|
||||||
i++ }
|
|
||||||
// XXX this feels hackish -- can this be deligated to the handler???
|
|
||||||
initial instanceof Array
|
|
||||||
&& initial.length++
|
|
||||||
continue }
|
|
||||||
|
|
||||||
// end of input...
|
// end of input...
|
||||||
if(i >= str.length-1){
|
if(i >= str.length-1){
|
||||||
|
|||||||
5
test.js
5
test.js
@ -228,11 +228,6 @@ test.Cases({
|
|||||||
|
|
||||||
// arrays...
|
// arrays...
|
||||||
['[1,2,]', '[1,2]'],
|
['[1,2,]', '[1,2]'],
|
||||||
|
|
||||||
// sparse arrays...
|
|
||||||
['[,]', '[<empty>]'],
|
|
||||||
['[1,2,,]', '[1,2,<empty>]'],
|
|
||||||
['[1,2,<empty>,]', '[1,2,<empty>]'],
|
|
||||||
],
|
],
|
||||||
'syntax-simplifications': function(assert){
|
'syntax-simplifications': function(assert){
|
||||||
var aa, bb
|
var aa, bb
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user