| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
```nim
echo newString(8)
```
results in:
```
D:\User\test.js:25
var code_33556944 = c_33556931.toString(16);
^
TypeError: Cannot read properties of undefined (reading 'toString')
at toJSStr (D:\User\test.js:25:50)
at rawEcho (D:\User\test.js:70:16)
at Object.<anonymous> (D:\User\test.js:101:1)
at Module._compile (node:internal/modules/cjs/loader:1095:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1147:10)
at Module.load (node:internal/modules/cjs/loader:975:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
at node:internal/main/run_main_module:17:47
Node.js v17.0.1
Error: execution of an external program failed: '"C:\Program Files\nodejs\node.exe" --unhandled-rejections=strict D:\User\test.js'
```
|
|
|
|
|
|
|
|
|
|
|
| |
* int64/uint64 as bigint in JS
* fix CI
* convert to compile option
* fix lie
* smaller diff, changelog entry
|
|
|
|
|
| |
* remove legacy code
* fixes
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Added 'openarray[char]' overloads to 'std/parseutils'
* Removed redundant `start` and `last` params from slice using procs
* Fixed type for parseIdent overload
* fixed one by off with 'substr'
* removed missed start parameters for procedures
* Added 'openarray[char]' overloads to 'std/parseutils'
* Removed redundant `start` and `last` params from slice using procs
* Fixed type for parseIdent overload
* fixed one by off with 'substr'
* removed missed start parameters for procedures
* Fixed VM op to work with new 'opcSlice'
* Corrected captureBetween's logic to work with openarray
* js sys's parsefloat logic now uses openarray
Co-authored-by: Clay Sweetser <Varriount@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
| |
* remove unused opcSubstr
* [js] add testcase for array indexDefect
* Revert "remove unused opcSubstr"
This reverts commit cb461f2545234d62c1e0b83318f3e5495c97de52.
|
| |
|
|
|
|
|
|
|
| |
* suggestion to respect typedarray
* Update jssys.nim
Co-authored-by: Sven Keller <s.keller@cortona.de>
|
| |
|
|
|
|
|
|
|
|
| |
* Assignments, which would accidentally create global
variables, instead throw an error in strict mode
* Assignment to a getter-only property
Co-authored-by: Sven Keller <s.keller@cortona.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
lineinfo, in all backends (c,vm,js) (#11955)
* fix #10053 FieldError for vm
* fixup
* FieldError now also shows runtime value of discriminant
* fix field error reporting in vm
* also report culprit line info in err msg
* fix errors for newruntime 2
* fix for js
* fixup
* PRTEMP4
* works
* works
* works perfect
* refactor
* std/private/repr_impl
* suppport --gc:arc
* cleanup
* refactor
* simplify
* simplify
* simplify
* fixup
* move out compiler.vmgen.genCustom
* fixup
* fixup
* add tests
* revert compiler/debugutils.nim
* simplify reprDiscriminant
* fixup
* lib/std/private/repr_impl.nim -> lib/system/repr_impl.nim
* try to fix D20210812T165220
* honor --declaredlocs
* control toFileLineCol via --declaredlocs
|
|
|
|
|
|
| |
* compiler/vmhooks: add getVar to allow vmops with var params
* addFloat vmops with var param
* cgen now renders float32 literals in c backend using roundtrip float to string
|
|
|
|
|
|
|
| |
* refs #7717 roundtrip float to string
* make parseFloat more correct
* improve float tests
* improve float tests
* cleanup
|
|
|
|
|
|
|
|
|
|
|
| |
* [std/re] make interface consistent
* tiny
* revert
* close #18129 add setCurrentException
* changelog entry
|
|
|
|
|
| |
* [backport:1.4] JS cstring null fixes
* fix JS move string
* make it look cleaner
|
| |
|
| |
|
|
|
|
| |
* Avoid creating a holey array in makeNimstrLit
* Use array index instead of push
|
|
|
|
|
|
|
| |
* add simple writeStackTrace for JS backend
* add testcase for writeStackTrace
* changelog
|
|
|
|
| |
* "eg" is a misspelled "egg", "e.g." is "exempli gratia"
* Also, "ie" is "i.e.".
|
| |
|
|
|
|
|
| |
function (#14230)
* fix https://github.com/timotheecour/Nim/issues/135 ; unify all file,line,col formatting into a single function
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* many bugfixes for js
fixes #12672, fixes #14153, closes #14123, closes #11331, fixes #11783, fixes #13966, fixes #14087, fixes #14117, closes #12256.
mostly fixes the fact that it was allowed to assign to newly created temp variables. additionally attempts to get rid of null initialized seqs/strings (though they might pop up here and there); this simplifies a lot of things and makes code size smaller. even if null seqs/strings pop up here and there it's still better than all those bugs existing.
* formatting fixes
* CI fixes
* more CI fixes
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Error -> Defect for defects
The distinction between Error and Defect is subjective,
context-dependent and somewhat arbitrary, so when looking at an
exception, it's hard to guess what it is - this happens often when
looking at a `raises` list _without_ opening the corresponding
definition and digging through layers of inheritance.
With the help of a little consistency in naming, it's at least possible
to start disentangling the two error types and the standard lib can set
a good example here.
|
|
|
|
|
| |
* StringStream & more stdlib modules support for JS/NimScript
* change back pegs test in line with #14134
|
|
|
|
|
|
|
|
|
| |
ints (#14134)
* fix https://github.com/timotheecour/Nim/issues/133; $(a: float) works in nim js like in other backends
* fix tests
* fix test for windows that prints 1.1e17 differently than other OS
|
| |
|
| |
|
|
|
|
|
| |
* JS: rewrote toJSStr
* JS: don't raise exceptions in primitives
|
| |
|
|
|
|
|
| |
* remove zeroExtend and friends from the compiler builtins.
* fix jssys
|
|
|
|
|
|
| |
* Make index out of bounds more useful by including the 'bounds'.
* fixes #9880 index out of bounds (remaining cases); revives #10228
* change err msg to: `index 3 not in 0 .. 1`
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add a test for issue #9389
* Fixes #9389.
* Make object contructors copy objects properly by checking whether the expressions passed to them don't need to be copied.
* Make mArrToSeq implementation actually check if a copy needs to be made.
* Avoid unnecessary copy in mChr impl
* Assume set constructor elements need no copy
* Add a test for issue #9410
* Add a test
* fix passing fat pointers (#9410)
* Enhance tests
* More tests and fixes
* Add more (failing) tests [ci skip]
* Added equality operator for fat pointers, more tests and fixes
* Fix printing uninitialized strings
* Fix mInc, mDec double eval, add more tests
* Tests
* Refactored, fixed multiple evals, revamped the tests, added missing ops
* Fix ups
* Fix #9643 and #9644
* add pointer normalization
|
| |
|
| |
|
|\ |
|
| | |
|
| | |
|
|/ |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* remove php
* fix
* keep nimphpext
* remove targetJS enum
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|