Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Aug 24, 2022. It is now read-only.

Commit 9c8317a

Browse files
committed
Merge pull request #9 from shenshouer/master
修复在1.5.1版本下报错:function multiply not defined
2 parents 84f3012 + 0548cea commit 9c8317a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

‎godoc/godoc.go‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,9 @@ func (p *Presentation) initFuncMap() {
9898

9999
// formatting of Notes
100100
"noteTitle": noteTitle,
101+
102+
// Number operation
103+
"multiply": multiply,
101104
}
102105
if p.URLForSrc != nil {
103106
p.funcMap["srcLink"] = p.URLForSrc
@@ -110,6 +113,8 @@ func (p *Presentation) initFuncMap() {
110113
}
111114
}
112115

116+
func multiply(a, b int) int { return a * b }
117+
113118
func filenameFunc(path string) string {
114119
_, localname := pathpkg.Split(path)
115120
return localname

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /