summaryrefslogtreecommitdiff
path: root/xmlWorksheet.go
diff options
context:
space:
mode:
authorxuri <xuri.me@gmail.com>2019-11-10 16:51:15 +0800
committerGitHub <noreply@github.com>2019-11-10 16:51:15 +0800
commitc8c8397751e994dca05467e7615f6ee77704775b (patch)
tree023a4a3d98b0efcd38860a062f4fe26de81cbb81 /xmlWorksheet.go
parent6abf8bf9723512086f009ca574bde1d6682fc83d (diff)
parentbf9a8355494eac18812f3caf6d469962824f627f (diff)
Fix #494 Merge pull request #514 from mlh758/fix-494-write-allocations
Reduce allocations when writing
Diffstat (limited to 'xmlWorksheet.go')
-rw-r--r--xmlWorksheet.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/xmlWorksheet.go b/xmlWorksheet.go
index 96ca235..8408cfa 100644
--- a/xmlWorksheet.go
+++ b/xmlWorksheet.go
@@ -430,6 +430,10 @@ type xlsxC struct {
XMLSpace xml.Attr `xml:"space,attr,omitempty"`
}
+func (c *xlsxC) hasValue() bool {
+ return c.S != 0 || c.V != "" || c.F != nil || c.T != ""
+}
+
// xlsxF directly maps the f element in the namespace
// http://schemas.openxmlformats.org/spreadsheetml/2006/main - currently I have
// not checked it for completeness - it does as much as I need.