Vimes.jl
Vimes.jl copied to clipboard
`using` statements should not be valid for `swaplines`
using statements are basically order free.
(unless you have code between them)
I got this diff:
diff --git a/./src/Foo.jl b/var/folders/1r/4cjj1xk90qbb6njj7dn_cmt40000gn/T/vimes-16332293967793207509/src/Foo.jl
index 458aba8..1915a99 100644
--- a/./src/Foo.jl
+++ b/var/folders/1r/4cjj1xk90qbb6njj7dn_cmt40000gn/T/vimes-16332293967793207509/src/Foo.jl
@@ -1,7 +1,7 @@
module Foo
-using Distributions
using LinearAlgebra: dot, norm
+using Distributions
using NamedDims
include("evaluate.jl")
That makes sense. Should be fairly easy to add a check for this.
Similarly for swapping method definitions. Should there be some way of putting a partial order on statements in a basic block and then only considering swaps that violate the partial order?