Skip to content
Snippets Groups Projects
Commit 270359c7 authored by Andrew E. Torda's avatar Andrew E. Torda
Browse files

formatting

parent cfb92ff8
No related branches found
No related tags found
No related merge requests found
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
// where input_file is a set of name-value pairs. These are defined with defaults // where input_file is a set of name-value pairs. These are defined with defaults
// in rdprm.go. At the moment, we have // in rdprm.go. At the moment, we have
package main package main
/* /*
{"ini_temp", "20"}, {"ini_temp", "20"},
{"final_temp", "1"}, {"final_temp", "1"},
......
...@@ -9,7 +9,6 @@ import ( ...@@ -9,7 +9,6 @@ import (
"testing" "testing"
) )
var tstTmpDir string var tstTmpDir string
func init() { func init() {
...@@ -39,6 +38,7 @@ func TestTypo(t *testing.T) { // Make sure a typo in input does provoke an error ...@@ -39,6 +38,7 @@ func TestTypo(t *testing.T) { // Make sure a typo in input does provoke an error
t.Fatal("line with typo should provoke error\n", err, "\nInput", sTypo) t.Fatal("line with typo should provoke error\n", err, "\nInput", sTypo)
} }
} }
type gentest struct{ params, basename string } type gentest struct{ params, basename string }
var set1 = []gentest{ var set1 = []gentest{
...@@ -69,7 +69,6 @@ ini_temp 0.18 ...@@ -69,7 +69,6 @@ ini_temp 0.18
final_temp 0.01 final_temp 0.01
x_ini 7,1,7 x_ini 7,1,7
n_step 100000`, "phasetrans"}, n_step 100000`, "phasetrans"},
} }
// addTestPath makes some of the loops below a bit more readable // addTestPath makes some of the loops below a bit more readable
......
...@@ -40,6 +40,7 @@ func maketicks(axisDscrpt axticks.AxisDscrpt) []chart.Tick { ...@@ -40,6 +40,7 @@ func maketicks(axisDscrpt axticks.AxisDscrpt) []chart.Tick {
} }
return t return t
} }
// maketicks this version works, but usually leaves you wanting one tick more. // maketicks this version works, but usually leaves you wanting one tick more.
/*func alt_maketicks(axisDscrpt axticks.AxisDscrpt, prcsn int) []chart.Tick { /*func alt_maketicks(axisDscrpt axticks.AxisDscrpt, prcsn int) []chart.Tick {
xmin, xmax, delta, prcsn := axisDscrpt.Xmin, axisDscrpt.Xmax, axisDscrpt.Delta, axisDscrpt.Prcsn xmin, xmax, delta, prcsn := axisDscrpt.Xmin, axisDscrpt.Xmax, axisDscrpt.Delta, axisDscrpt.Prcsn
......
...@@ -40,10 +40,10 @@ func setSuffix(fname, suffix string) (string, error) { ...@@ -40,10 +40,10 @@ func setSuffix(fname, suffix string) (string, error) {
// We do not check for single, unmatched quotes. If you want a file // We do not check for single, unmatched quotes. If you want a file
// called "fname you should use some other program. // called "fname you should use some other program.
func removeQuotes(s string) string { func removeQuotes(s string) string {
for ; len(s) > 0 && s[0] == '"' ;{ for len(s) > 0 && s[0] == '"' {
s = s[1:] s = s[1:]
} }
for ; len(s) > 0 && s[len(s)-1] == '"' ; { for len(s) > 0 && s[len(s)-1] == '"' {
s = s[:len(s)-1] s = s[:len(s)-1]
} }
return s return s
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment