manterolat
16a941a642
Fixes #9154 ( #9193 )
2018-10-10 13:17:28 +02:00
LemonBoy
ee14ace5d3
Field checks for everybody ( #8957 )
...
* Field checks for JS backend
* Clean nkCall nodes with no arguments
Generating a nkEmpty in place of no arguments makes no sense form the
AST point of view and also trips up the VM codegen.
* Field checks for VM backend
* Test case for #6612
This patchset fixes #6612
* Add test case for LHS double evaluation
* Prevent LHS double-eval for JS backend
* Prevent double evaluation in VM backend
2018-10-09 19:54:12 +02:00
LemonBoy
a3fb0a769c
Try/Catch support for native JS exceptions ( #8955 )
...
* Try/Catch support for native JS exceptions
* Better tests
2018-10-09 19:51:29 +02:00
LemonBoy
b97a7dbf3d
Make the registered passes local to the ModuleGraph ( #9259 )
...
Closes #9068
2018-10-09 19:24:02 +02:00
Araq
5709736e82
Merge branch 'devel' into araq-better-docgen
2018-09-14 15:48:07 +02:00
LemonBoy
87955eaf30
Fix concat behaviour for uninitialized strings ( #8950 )
2018-09-11 23:35:21 +02:00
LemonBoy
9ba80d2044
JS strings have no trailing zero anymore ( #8936 )
2018-09-11 11:45:02 +02:00
Araq
e06a89e112
fixes bootstrapping problems
2018-09-07 19:21:17 +02:00
Andreas Rumpf
86556ebfdb
compiler refactoring; use typesafe path handing; docgen: render symbols between modules
2018-09-07 19:21:16 +02:00
LemonBoy
84eab97fed
Sync line generation between C and JS backends ( #8888 )
...
Fixes #7224
2018-09-07 01:56:36 +02:00
LemonBoy
af1e84f54d
Automatic deref for everything but pointers in asm/emit ( #8891 )
...
Fixes #7249
2018-09-07 01:54:59 +02:00
LemonBoy
1a60ffcf1d
Correctly mangle this in the JS backend ( #8853 )
...
As shown in pragmagic/karax#67 using `this` as parameter name made the
codegen output wrong code (and the user didn't notice the errors in the
browser console).
2018-09-03 17:51:30 +02:00
Araq
64517445ea
even more strict isNil handling for strings/seqs in order to detect bugs
2018-08-22 12:35:46 +02:00
Andreas Rumpf
dae5450947
WIP: disallow 'nil' for strings and seqs
2018-08-13 11:41:33 +02:00
andri lim
4d5cce9882
fixes #6255 , add system.ashr arithmetic right shift ( #8547 )
2018-08-07 18:41:30 +02:00
Andreas Rumpf
9ab92824f6
AST change: keep nkStaticStmt in the AST for incremental compilation support
2018-06-03 20:16:29 +02:00
Andreas Rumpf
826c1e2d78
incremental compilation: implemented basic replay logic
2018-06-02 09:41:27 +02:00
Andreas Rumpf
61fb83ecbb
baby steps for incremental compilation
2018-05-30 23:50:34 +02:00
Andreas Rumpf
db4bcd80e5
jsgen refactoring: use graph.backend field instead of a global variable
2018-05-28 12:24:18 +02:00
Andreas Rumpf
669a564492
remove more global variables in the Nim compiler
2018-05-27 11:10:56 +02:00
Andreas Rumpf
a4e2b0c153
platform.nim doesn't use globals anymore; prepare msgs.nim for not using globals
2018-05-18 15:18:00 +02:00
Andreas Rumpf
bf6c2c5ccf
preparations of making compiler/msgs.nim free of global variables
2018-05-17 15:21:22 +02:00
Andreas Rumpf
328e7a1005
options.nim: no global variables anymore
2018-05-13 17:52:21 +02:00
Andreas Rumpf
8ca5b71c6a
the remaining passes all compile again
2018-05-13 00:45:52 +02:00
Andreas Rumpf
33b69f0ed0
refactoring: make FileIndex a distinct type; make line information an uint16; fixes #7654
2018-04-21 08:13:37 +02:00
treeform
35b0cc67e8
Remove PHP backend. ( #7606 )
...
* remove php
* fix
* keep nimphpext
* remove targetJS enum
2018-04-18 20:40:11 +02:00
Andreas Rumpf
9e884c31dd
the new feature's name is hotCodeReloading
2018-04-13 23:48:56 +02:00
Andreas Rumpf
d7cc9016f3
fixes #4470
2018-04-13 23:41:31 +02:00
zah
e3037a2f33
Support code hot reloading for JavaScript projects ( #7362 )
...
* Support code hot reloading for JavaScript projects
* Add some missing JavaScript symbols and APIs
* fix the Travis build
* (review changes) remove the js type from the standard library as it doesn't follow NEP-1
* more additions to the DOM module
* Follow NEP-1 in jsffi; spell 'hot code reloading' correctly
* introduce a jscore module
* Document jscore module.
* readded js type
* Remove the '$' operator that doesn't behave
2018-04-13 19:08:43 +02:00
Andreas Rumpf
47335aab41
introduce nkTupleConstr AST node for unary tuple construction; breaking change
2018-04-13 17:45:58 +02:00
Andreas Rumpf
70e8640244
move new sha1 module into the new 'std' namespace
2018-02-06 17:40:31 +01:00
Andreas Rumpf
274fafb2df
fixes #6961
2018-02-02 17:35:04 +01:00
GULPF
94038545be
Fixes codegen bug with literal negative zero, fixes #7079 ( #7158 )
...
* Fixes #7079
* Fix handling of neg zero during constant folding
2018-01-31 16:29:42 +01:00
Andreas Rumpf
a605fa8ba6
fixes #7129
2018-01-30 19:51:38 +01:00
Andreas Rumpf
1d9087245c
JS codegen bugfix: don't crash on wrong importcpp patterns
2018-01-25 16:02:13 +01:00
Andreas Rumpf
e4081a7201
preparations for language extensions: 'sink' and 'lent' types
2018-01-07 23:09:26 +01:00
qqquinta
d5f539dc87
jsgen: bool genConv generates boolean values instead of numeric ( #7016 )
2018-01-03 12:40:19 +01:00
Araq
ee67a67ac4
first steps in adding template/macro calls to stack traces
2017-12-21 10:03:33 +01:00
Araq
8decf0f5ce
make JS tests green again
2017-12-15 11:34:17 +01:00
Alexander Ivanov
1699d7c2a4
Implement codegenDecl for js ( #6851 )
2017-12-01 15:42:10 +01:00
Andreas Rumpf
85b00aff56
fixes #6445 (concepts for the JS target)
2017-11-22 12:58:03 +01:00
Andreas Rumpf
75dd3763cf
fixes #6568
2017-11-22 12:58:03 +01:00
Andreas Rumpf
0d11e09729
fixes #6753
2017-11-18 15:19:06 +01:00
skilchen
e4b0818629
fixes #6532 array bounds check for non zero based arrays on the js backend ( #6550 )
2017-11-06 09:14:28 +01:00
Andreas Rumpf
70ea45cdba
deprecated unary '<'
2017-10-29 08:37:13 +01:00
Andreas Rumpf
f7f3a25be8
first steps of making 'opt' a first class type for Nim
2017-09-25 13:19:36 +02:00
Andreas Rumpf
e879da5791
some work to make 'opt' a first class type
2017-09-24 11:21:52 +02:00
Andreas Rumpf
1a61c4d46d
first implementation of the 'func' keyword
2017-09-23 23:22:53 +02:00
Araq
f127a7f7aa
fixes #6096
2017-07-17 16:43:10 +02:00
Andreas Rumpf
5932ad9ae8
fixes a JS codegen regression
2017-07-10 16:40:23 +02:00