Skip to content
Branch: master
Find file History
mvdan syntax: make SplitBraces work in-place
This makes it consistent with Simplify. Modifying nodes in-place is
better than generating copies, because most of the time the user doesn't
need both in memory at once.

In the rare cases that one does have that need, it's always possible to
print and re-parse the node, as a simple way to do a deep copy.

On the other hand, if the API always makes a full copy by design,
there's no way to work around that extra garbage generation.
Latest commit 0a1767d Jun 12, 2019
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
braces.go syntax: make SplitBraces work in-place Jun 14, 2019
canonical.sh syntax: enforce indentation of <<- heredoc bodies Apr 22, 2018
doc.go all: remove comments enforcing vanity imports Jul 17, 2018
example_test.go syntax: get rid of StmtList Mar 12, 2019
filetests_test.go syntax: refactor how escaped newlines are handled Jun 2, 2019
lexer.go syntax: fix escaped newline crash in heredocs Jun 3, 2019
nodes.go syntax: don't parse options in DeclClause May 19, 2019
nodes_test.go syntax,interp: mark all tests as parallel Jul 14, 2018
parser.go syntax: refactor how escaped newlines are handled Jun 2, 2019
parser_test.go syntax: fix escaped newline crash in heredocs Jun 3, 2019
pattern.go interp: use globbing more conservatively Sep 15, 2018
pattern_test.go syntax,interp: mark all tests as parallel Jul 14, 2018
printer.go syntax: fix nested <<- printer crash Jun 4, 2019
printer_test.go syntax: fix nested <<- printer crash Jun 4, 2019
quotestate_string.go syntax: add support for the bitwise negation op ~ Mar 26, 2019
simplify.go syntax: make SplitBraces work in-place Jun 14, 2019
simplify_test.go syntax: parse [[ X = Y ]] without changes Mar 25, 2019
token_string.go syntax: add support for the bitwise negation op ~ Mar 26, 2019
tokens.go syntax: add support for the bitwise negation op ~ Mar 26, 2019
walk.go syntax: don't parse options in DeclClause May 19, 2019
walk_test.go syntax: don't skip Hdoc in Redirect.End Dec 2, 2018
You can’t perform that action at this time.