TheSwanFactory / hclang

Homoiconic C - a universal data format for computation
https://theswanfactory.wordpress.com/2016/12/20/homoiconic-c-a-universal-language-for-code-and-data/
MIT License
4 stars 0 forks source link

format docstrings across lines #177

Closed drernie closed 1 year ago

drernie commented 1 year ago

Right now it inserts "$$" instead of newlines.

.hc 0.5.3;
; ```
; This is test
; ```
# “$$This is test$$”
drernie commented 1 year ago

But the unit test works!?!

    it('joins multi-line doc-strings into strings', () => {
      const input = '```\nDoc String\n```'
      const result = evaluate(input)
      expect(result.toString()).to.equal('[“\nDoc String\n”]')
    })

Why doesn't the interpreter and the test doc?

drernie commented 1 year ago

Ah. Readline. Need to call evaluate Repeatedly.