Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


Inconsistent arguments in beautify.js #139

PlNG opened this Issue · 2 comments

2 participants


In some places get_next_token is being passed parser_pos as an argument but the function is using this globally?


In some places print_newline is being passed true as an argument but the function is internally setting this argument as the undefined default value: true.

This is a consistency issue is all.


Yes, you're right, in those places where parser_pos is passed to get_next_token, that is a historic leftover and completely unnecessary,

yet I don't understand the problem you see with the optional ignore_repeated argument; if it is not passed in, then it gets default value of true, otherwise the passed value:

print_newline(); // ignore_repeated = true
print_newline(true); // ignore_repeated = true
print_newline(false); // ignore_repeated = false

I guess this can be closed.

@einars einars closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.