| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
fixes #21441
When compiling for JS, nimscript config files have both `defined(js)`
and `defined(nimscript)` be true at the same time. This is required so
that the nimscript config file knows the current compilation is for the
JS backend. However the system module doesn't account for this in some
cases, defining JS-specific code or not defining nimscript-specific code
when compiling such nimscript files. To fix this, have the `nimscript`
define take priority over the `js` one.
|
|
|
| |
fixes jsbigint64 regression
|
|
|
|
|
|
|
| |
makes new hash the default, with an opt-out (& js-no-big-int) define.
Also update changelog (& fix one typo).
Only really expect the chronos hash-order sensitive test to fail until
they merge that PR and tag a new release.
|
| |
|
|
|
| |
fixes #23522
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
fixes #4695
ref https://github.com/nim-lang/Nim/pull/15818
Since `nkState` is only for the main loop state labels and `nkGotoState`
is used only for dispatching the `:state` (since
https://github.com/nim-lang/Nim/pull/7770), it's feasible to rewrite the
loop body into a single case-based dispatcher, which enables support for
JS, VM backend. `nkState` Node is replaced by a label and Node pair and
`nkGotoState` is only used for intermediary processing. Backends only
need to implement `nkBreakState` and `closureIterSetupExc` to support
closure iterators.
pending https://github.com/nim-lang/Nim/pull/23484
<del> I also observed some performance boost for C backend in the
release mode (not in the danger mode though, I suppose the old
implementation is optimized into computed goto in the danger mode)
</del>
allPathsAsgnResult???
|
|
|
|
|
|
|
|
|
|
| |
variable `_` (#23498)
According to
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/Expression_statement,
some expression statements need parentheses to make it unambiguous. `_`
introduced in the https://github.com/nim-lang/Nim/pull/15789 is
unnecessary. We can get rid of it by adding parentheses so that object
literals are not ambiguous with block statements.
|
|
|
|
|
|
|
|
| |
fixes #4299
fixes #12492
fixes #10849
It binds `function` with `env`: `function.bind(:env)` to ease codegen
for now
|
| |
|
|
|
|
|
|
|
|
| |
(#23377)
Windows's nodejs `isAbsolute` issue has been resolved by [this
PR](https://github.com/nim-lang/Nim/pull/23365).
So we can improve the coverage for Windows.
|
|
|
| |
Closes #13341
|
| |
|
|
|
| |
fixes #21208
|
|
|
|
|
|
|
|
|
|
|
| |
* fix VM uint conversion bug, stricter int gen on JS
fixes #19929
* fix float -> uint64 conversion too
* no need to mask to source type
* simpler diff with explanation, add test for described issue
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a rebase of an earlier rejected PR. Following the discussion
around it, this commit provides a valid output for and edge case
of an empty separator for `split` and `rsplit` routines. The empty
separator is interpreted as "split by no separators" and the initial
string is returned. This is consistent with the behaviour of the
`set[char]` version of `split`/`rsplit` routines and unifies them all.
Compared to a commit merged earlier, this one has a benefit of
not using assertions that will be removed in release builds
and thus still not preventing possible infinite loops (which was the
earlier behaviour for this edge case for separator of type `string`).
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* move sha1, md5 to nimble packages
* boot the compiler
* fixes tests
* build the documentation
* fixes docs
* lol, I forgot koch.nim
* add `nimHasChecksums` define
* clone checksums but maybe copying is better
* bump nimble hash
* use ChecksumsStableCommit
* fixes tests
* deprecate them
* fixes paths
* fixes koch
|
|
|
|
|
|
|
|
|
|
|
| |
* stdlib tests now check refc too
* typo
* fixes line numbers
* disable cpp
* do not touch
|
|
|
|
|
|
|
|
|
|
|
| |
* int64/uint64 as bigint in JS
* fix CI
* convert to compile option
* fix lie
* smaller diff, changelog entry
|
|
|
|
|
| |
* fixes #21439; Add tyOpenArray to genTypeInfo.
* Add test.
|
|
|
|
|
|
|
| |
* Add test case
* closes #21247 Add the sfAddrTaken flag to var parameters in converters
This allows the JS backend to properly pass the parameter as a fat pointer
|
|
|
|
|
| |
* Add test case
* Implement JS async transform for nnkProcTy
|
| |
|
|
|
|
|
| |
* Add test case
* Extend string with '0' when setting length to be longer
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Parse the new line format
* Fix pattern
Didn't have space after the path
* Remove duplicate sources
Sources would sometimes double up with a new line at the end
* Remove unused variable
* Refactor sourcemap.nim
Removes the multiple translations needed, now goes from single high level type to the final SourceMap
Adds documentation for procs
* Line numbers line up properly now
Files aren't linking correctly though
* Files now link up correctly
Lines are sometimes off but overall seems pretty good
Just need to implement parser
* Add column info to output
Add sourceMappingURL to rope directly to prevent copy
* Properly handle columns
* Remove debug lines
* Add testcase
* Finish testcase
* Use the outdir folder instead of the folder the test is in to find the sourcemap
Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* remove db stuffs
* remove punycode
* remove
* fixes script
* add cloner
* patches
* disable
* patch
* fixes external packages
* disable two packages
* preview documentation build
* try again
* fixes URL
* fixes a bug
* simplify
* fixes documentaion
* fixes
* Apply suggestions from code review
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* test disable do: block lambda lifting
* fix last test [skip ci]
* deprecate `do:` meaning `do ():` + misc cleanup
closes https://github.com/nim-lang/RFCs/issues/486
* oops
* fix
* no idea what could be causing nimsuggest failure other than this
* ensure ci works
|
|
|
|
|
|
|
|
|
| |
* move `smtp` to nimble packages
* fixes
* install smtp
* yes
|
|
|
|
|
|
|
| |
(#20548)
* fix #8821 JS codegen can produce extreme switch statements with case a of range
* remove totalRange
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* fresh start
* add cpp target
* add result support
* add nimPreviewRangeDefault
* reduce
* use orc
* refactor common parts
* add tuple support
* add testcase for tuple
* cleanup; fixes nimsuggest tests
* there is something wrong with cpp
* remove
* add support for seqs
* fixes style
* addd initial distinct support
* remove links
* typo
* fixes tuple defaults
* add rangedefault
* add cpp support
* fixes one more bugs
* add more hasDefaults
* fixes ordinal types
* add testcase for #16744
* add testcase for #3608
* fixes docgen
* small fix
* recursive
* fixes
* cleanup and remove tuple support
* fixes nimsuggest
* fixes generics procs
* refactor
* increases timeout
* refactor hasDefault
* zero default; disable i386
* add tuples back
* fixes bugs
* fixes tuple
* add more tests
* fix one more bug regarding tuples
* more tests and cleanup
* remove messy distinct types which must be initialized by original types
* add tests
* fixes zero default
* fixes grammar
* fixes tests
* fixes tests
* fixes tests
* fixes comments
* fixes and add testcase
* undo default values for results
Co-authored-by: flywind <43030857+xflywind@users.noreply.github.com>
|
|
|
|
|
| |
* move widestrs out of system
* fix osproc
|
| |
|
|
|
|
|
|
|
|
|
| |
* remove unused opcSubstr
* [js] add testcase for array indexDefect
* Revert "remove unused opcSubstr"
This reverts commit cb461f2545234d62c1e0b83318f3e5495c97de52.
|
|
|
| |
fix #19330; fix #19059
|
|
|
|
|
|
|
| |
* Optimize lent in JS [backport:1.6]
* addr on lent doesn't work anymore, don't use it
* use unsafeAddr in test again for older versions
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* deprecate unsafeAddr; extend addr
addr is now available for all addressable locations, unsafeAddr is deprecated and become an alias for addr
* follow @Vindaar's advice
* change the signature of addr
* unsafeAddr => addr (stdlib)
* Update changelog.md
* unsafeAddr => addr (tests)
* Revert "unsafeAddr => addr (stdlib)"
This reverts commit ab83c99c507048a8396e636bf22d55fdd84d7d1c.
* doc changes; thanks to @konsumlamm
Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
| |
* Use openarray of bytes in md5
* fix CI
* cleanup
* use noSideEffect for bootstrapping
* fix CI again
* actually fix CI by checking if it works
* this is getting ridiculous
* put old md5 version in compiler, remove vmop
|
|
|
|
|
| |
* style usages (openArray)
* revert doc changes
|
|
|
|
|
| |
* add new modules, except experimental ones
* remove deprecated modules mersenne and sharedlist
* better describe why some modules fail and some modules don't
|
|
|
|
|
| |
* envPairs works in vm, nims
* fixup
|
|
|
|
|
|
|
|
|
| |
* fix upstream changes
* Update tests/js/tunittest_error2.nim
Co-authored-by: flywind <xzsflywind@gmail.com>
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
|
|
|
|
| |
nested templates (#18082)
|
|
|
|
|
|
|
|
|
|
| |
* followup #16871 asyncjs.then: allow pipelining procs returning futures
* rename test files where they belong
* fix tests
* tests for then with `onReject` callback
* rename test file containing fail to avoid messing with grep
* address comments
* cleanup
* un-disable 1 test
|
|
|
|
|
|
|
|
|
| |
* remove unnecessary when statement
* remove outdated codes
* fix #17177
* add testcase
|
|
|
|
|
|
| |
* asyncjs: add then
* improve tests, changelog, API
* fix cryptic windows error: The parameter is incorrect
* address comments
|
|
|
|
|
|
|
| |
* array litterals uses typed arrays
* Update compiler/jsgen.nim
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com>
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* basic stability improvements; refs nimsuggest
* fixed dot operator recursive loop & macro suggest
* hacky fix for run away dot operator sem check
Committing this mostly to make the issue more clear. Perhaps get better
feedback.
* semExprWithType seems like a better place to check
* fixed error messages const case expressions
* Clean-up test
* stopped the dot operator madness
No longer get infinite recursion when seming broken code with a dot
operator macro like in jsffi.
Co-authored-by: Araq <rumpf_a@web.de>
|
|
|
|
| |
* fix #16978 unittest js foreign exception
|
|
|
|
|
|
|
|
|
| |
* Make parseopt available on all backends
* fix spaces
* fix getopt and update prelude
* no crazy unnecessary version checks, use doAssert
|
|
|
|
|
| |
* [backport:1.4] JS cstring null fixes
* fix JS move string
* make it look cleaner
|