Skip to content

Commit

Permalink
[66_7] herk->utf8 and utf8->herk
Browse files Browse the repository at this point in the history
  • Loading branch information
da-liii authored Oct 3, 2024
1 parent 27f938c commit de9fe38
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
11 changes: 11 additions & 0 deletions TeXmacs/tests/66_7.scm
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
(import (liii check))

(define (test-single-quote)
(let ((cork_60 (string (integer->char #x60)))
(cork_27 (string (integer->char #x27))))
(check (utf8->herk "‘’") => (string-append cork_60 "<#2019>"))
(check (herk->utf8 (string-append cork_60 "<#2019>")) => "‘’")))


(tm-define (test_66_7)
(test-single-quote))
16 changes: 16 additions & 0 deletions src/Scheme/L3/glue_moebius.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,22 @@ function main()
arg_list = {
"string"
}
},
{
scm_name = "utf8->herk",
cpp_name = "utf8_to_herk",
ret_type = "string",
arg_list = {
"string"
}
},
{
scm_name = "herk->utf8",
cpp_name = "herk_to_utf8",
ret_type = "string",
arg_list = {
"string"
}
},
-- routines for strings in the TeXmacs encoding
{
Expand Down

0 comments on commit de9fe38

Please sign in to comment.