diff --git a/gnucash/report/report-system/html-acct-table.scm b/gnucash/report/report-system/html-acct-table.scm
index 1cf5a4d635..f67129c47b 100644
--- a/gnucash/report/report-system/html-acct-table.scm
+++ b/gnucash/report/report-system/html-acct-table.scm
@@ -495,6 +495,8 @@
;; user. This class simply maps its contents to the html-table.
;;
+(use-modules (srfi srfi-9))
+
;; this is to work around a bug in the HTML export sytmem
;; which causes COLSPAN= attributes not to be exported (!!)
(define gnc:colspans-are-working-right
@@ -506,23 +508,14 @@
;; utility class for generating account tables
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(define
- (make-record-type ""
- '(matrix ;; an html-table
- env ;; an alist
- )))
-
-(define gnc:html-acct-table?
- (record-predicate ))
-
-(define gnc:_make-html-acct-table_
- (record-constructor ))
+(define-record-type
+ (gnc:_make-html-acct-table_ matrix env)
+ gnc:html-acct-table?
+ (matrix gnc:_html-acct-table-matrix_ gnc:_html-acct-table-set-matrix!_)
+ (env gnc:_html-acct-table-env_ gnc:_html-acct-table-set-env!_))
(define (gnc:make-html-acct-table)
- (gnc:_make-html-acct-table_
- (gnc:make-html-table) ;; matrix
- #f ;; env
- ))
+ (gnc:_make-html-acct-table_ (gnc:make-html-table) #f))
(define (gnc:make-html-acct-table/env env)
(let ((acct-table (gnc:make-html-acct-table)))
@@ -538,18 +531,6 @@
(gnc:html-acct-table-add-accounts! acct-table accts)
acct-table))
-(define gnc:_html-acct-table-matrix_
- (record-accessor 'matrix))
-
-(define gnc:_html-acct-table-set-matrix!_
- (record-modifier 'matrix))
-
-(define gnc:_html-acct-table-env_
- (record-accessor 'env))
-
-(define gnc:_html-acct-table-set-env!_
- (record-modifier 'env))
-
;; some useful predicates to export
(define (gnc:account-code-less-p a b)
(string (xaccAccountGetCode a)