Skip to content

Commit d499cd7

Browse files
committed
Forgoten to commit
1 parent b052dd8 commit d499cd7

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

DiffBackend/src/main.lisp

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,14 @@
7777
(values ast-tree-1 ast-tree-2)))
7878

7979
(defun get-abstract-sem-tree-from-string (str cur-file)
80-
(abstract-sem-tree-gen (parser (lexer str)) :curr-file cur-file))
80+
(multiple-value-bind (res-lexems comments lex-errors)
81+
(lexer str)
82+
(when lex-errors
83+
(error "Lex errors !!! ~A" lex-errors))
84+
(when (> (hash-table-count comments) 0)
85+
(cond ((= cur-file 1)
86+
(setf *comment-table-1* comments))
87+
((= cur-file 2)
88+
(setf *comment-table-2* comments))
89+
(t (error "Error value of cur-file"))))
90+
(abstract-sem-tree-gen (parser res-lexems) :curr-file cur-file)))

DiffBackend/src/results-generator.lisp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
:diff-backend/lexer
66
:diff-backend/statistics)
77
(:export #:get-json-res
8-
#:get-stats-res))
8+
#:get-stats-res
9+
#:get-json-comments))
910

1011
(in-package :diff-backend/results-generator)
1112

0 commit comments

Comments
 (0)