Link each template in steps that each return what they build, create a name scope with its owner in one place, and settle each record's columns at load, so Generator.records goes
This commit is contained in:
+2
-2
@@ -45,8 +45,8 @@ func shippedShape(f *Generator) string {
|
||||
}
|
||||
case *template:
|
||||
facts[prefix] = "\tformat " + strconv.Quote(n.format) + readsFact(n)
|
||||
if _, columns, err := recordOf(n); err == nil {
|
||||
for _, c := range columns {
|
||||
if record, err := recordOf(n); err == nil {
|
||||
for _, c := range record.columns {
|
||||
fact := "\t" + c.DataType.String()
|
||||
if _, nullable := columnItems(n.fields[c.Name]); nullable {
|
||||
fact += " null"
|
||||
|
||||
Reference in New Issue
Block a user