diff options
| author | Bruce Hill <bitbucket@bruce-hill.com> | 2018-07-10 17:10:37 -0700 |
|---|---|---|
| committer | Bruce Hill <bitbucket@bruce-hill.com> | 2018-07-10 17:10:59 -0700 |
| commit | 3fd5687370c3ef28c1878a79f0b4173e7212795f (patch) | |
| tree | 25282d62a576a65e930fd47459d9c9ce05109f90 /code_obj.moon | |
| parent | 77a551099a1d7c1d45036bf14301f7841ee8b8ca (diff) | |
Fixed up line numbers for generated code.
Diffstat (limited to 'code_obj.moon')
| -rw-r--r-- | code_obj.moon | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/code_obj.moon b/code_obj.moon index 74e9a15..8ac7146 100644 --- a/code_obj.moon +++ b/code_obj.moon @@ -48,7 +48,7 @@ class Code @bits, @indents, @current_indent = {}, {}, 0 if type(@source) == 'string' @source = Source\from_string(@source) - assert(@source and Source\is_instance(@source)) + assert(@source and Source\is_instance(@source), "Source has the wrong type") @append(...) append: (...)=> @@ -57,7 +57,7 @@ class Code match = string.match for i=1,n b = select(i, ...) - assert(b) + assert(b, "bit is nil") if b == '' then continue bits[#bits+1] = b if type(b) == 'string' |
