HVML / PurC

The prime HVML interpreter for C Language.
GNU Lesser General Public License v3.0
1.06k stars 54 forks source link

给 purc 输出的 HTML 加一个 pretty printer 过滤 #13

Closed tiansiyuan closed 1 year ago

tiansiyuan commented 2 years ago

现在(Ubuntu 22.04.1 LTS)的输出是这样的:

tsy@tsy-Lenovo-V330-14IKB:~/PurC/build$ purc -b hvml/fibonacci-html-temp.hvml purc 0.8.0 Copyright (C) 2022 FMSoft Technologies. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

Executing HVML program from file:///home/tsy/PurC/build/hvml/fibonacci-html-temp.hvml...

The main coroutine exited.

The document generated:

Fibonacci Numbers

Fibonacci Numbers less than 2000

  1. 0
  2. 1
  3. 1
  4. 2
  5. 3
  6. 5
  7. 8
  8. 13
  9. 21
  10. 34
  11. 55
  12. 89
  13. 144
  14. 233
  15. 377
  16. 610
  17. 987
  18. 1597

Totally 18 numbers

The executed result: [ 18, 1597 ]

经 pretty printer 过滤后的 HTML 部分看起来:

Fibonacci Numbers

Fibonacci Numbers less than 2000

  1. 0
  2. 1
  3. 1
  4. 2
  5. 3
  6. 5
  7. 8
  8. 13
  9. 21
  10. 34
  11. 55
  12. 89
  13. 144
  14. 233
  15. 377
  16. 610
  17. 987
  18. 1597

Totally 18 numbers

tiansiyuan commented 2 years ago

HTML 被 github 渲染了,请见附件:beforepp.txt 和 afterpp.txt。 beforepp.txt

afterpp.txt

VincentWei commented 2 years ago

Indeed, this is a bug. We will try to fix it in the next release.

VincentWei commented 1 year ago

This issue has been fixed and/or enhanced.