asiva@google.com
f4fe42c280
Added macros OBJECT_IMPLEMENTATION and FINAL_OBJECT_IMPLEMENTATION
...
which have different implementations of 'operator=' and 'operator^='.
In the case of FINAL_OBJECT_IMPLEMENTATION we do not do the vtable setting
in these methods (Note the |= operator functionality is now subsumed into
the new implementation of "operator^=")
Review URL: https://codereview.chromium.org//12052033
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17491 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-23 20:01:31 +00:00
srdjan@google.com
7159a6f103
Some more ^= to |=
...
Review URL: https://codereview.chromium.org//12017020
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17310 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-18 20:43:33 +00:00
hausner@google.com
7e70aaddf7
Support for embedded Dart scripts
...
Add a line and column offset to scripts so that errors and exceptions
in embedded Dart scripts are reported at the proper location.
New API call Dart_LoadEmbeddedScript() that allows to specify
line and column offsets.
Stumbled on and fixed a bug. Script::kind field was not externalized to snapshot.
Review URL: https://codereview.chromium.org//11824067
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16934 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-10 21:47:09 +00:00
asiva@google.com
7022b39e35
Convert all symbol accessors to return read only handles so that it is not necessary to create a new handle in the code that uses it.
...
Added a few more strings to the symbols list.
Review URL: https://codereview.chromium.org//11667012
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16584 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-02 19:31:59 +00:00
asiva@google.com
02049c689e
Fix for issue 7089 (Symbols::New was not quite working correctly
...
when there are non ASCII Latin-1 characters in the string).
Review URL: https://codereview.chromium.org//11411341
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15711 260f80e4-7a28-3924-810f-c04153c831b5
2012-12-04 22:18:12 +00:00
cshapiro@google.com
39ee2fdfeb
Move various top-level Unicode definitions into classes and methods.
...
Review URL: https://codereview.chromium.org//11414249
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15568 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-30 03:33:37 +00:00
cshapiro@google.com
979571d3ee
Use a signed 32-bit integer for representing code points.
...
Review URL: https://codereview.chromium.org//11419086
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15188 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-21 00:30:27 +00:00
erikcorry@google.com
84da84c22d
Revert "Add some support for the code-point code-unit distinction."
...
This reverts commit r15150
R=karlklose@google.com
BUG=
Review URL: https://codereview.chromium.org//11411092
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15152 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-20 15:23:41 +00:00
erikcorry@google.com
547cbf9da6
Add some support for the code-point code-unit distinction.
...
Adds String.fromCodeUnits and String.codeUnitAt, and modifies
String.fromCodePoints and String.codePointAt to actually use code points.
Fixes String.charCodes to use code points and adds String.codeUnits.
Reenables some tests, and adds new ones for non-BMP characters.
Fixes issues 6418, 6501 and 1357.
R=floitsch@google.com
BUG=
Review URL: https://codereview.chromium.org//11368138
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15150 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-20 14:51:25 +00:00
hausner@google.com
f116c93cf9
Proper reporting of illegal characters in source code
...
Fixes bug 6778.
Review URL: https://codereview.chromium.org//11417074
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15122 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-19 23:46:23 +00:00
iposva@google.com
7ae807a19c
- Move MathNatives from dart:core to dart:math.
...
- Split out double and integer parsing from MathNatives.
Review URL: https://codereview.chromium.org//11316031
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15032 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-16 19:42:02 +00:00
hausner@google.com
95c79712da
Make library, import, export, part pseudo-keywords
...
Resubmit cl 14446 after Ivan's keyword table fix.
Review URL: https://codereview.chromium.org//11367069
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14500 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 20:30:08 +00:00
iposva@google.com
4d410f0ebb
- Prepopulate the keyword symbol table otherwise we can end up
...
with empty spots when reading from a snapshot.
Review URL: https://codereview.chromium.org//11366058
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14453 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 07:29:12 +00:00
hausner@google.com
e4880d6698
Revert cl 14446
...
Review URL: https://codereview.chromium.org//11293054
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14448 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-02 00:19:48 +00:00
hausner@google.com
4c6b490ab8
Make library, import, export, part built-in identifiers
...
Review URL: https://codereview.chromium.org//11360051
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14446 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-01 23:47:25 +00:00
hausner@google.com
784b159e2f
Eliminate support for old raw string format
...
Review URL: https://codereview.chromium.org//11043010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13145 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-02 21:54:46 +00:00
hausner@google.com
731f692895
Get rid of #resource directive in VM
...
Review URL: https://codereview.chromium.org//10918226
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12358 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-13 22:25:09 +00:00
hausner@google.com
8f5eea3291
Support r"xxx" raw strings
...
Review URL: https://chromiumcodereview.appspot.com//10914213
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12225 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-11 22:53:45 +00:00
hausner@google.com
22fdbae05b
VM can parse and ignore metadata
...
Support parsing of metadata in all legal locations except library
and import directives. The metadata is simply ignored. It is not
evaluated or validated for correctness.
Review URL: https://chromiumcodereview.appspot.com//10913138
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12078 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-07 23:06:48 +00:00
cshapiro@google.com
da14bf70a7
Add attributions so printf like functions can have their arguments checked.
...
This change also corrects some misuses of format strings and format
arguments that discovered by the compiler checks.
Review URL: https://chromiumcodereview.appspot.com//10869063
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11912 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 00:58:25 +00:00
asiva@google.com
ed8db0f611
Move more symbols to the vm isolate.
...
Review URL: https://chromiumcodereview.appspot.com//10808111
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9905 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-25 20:31:26 +00:00
hausner@google.com
fdd91990f1
Implement cascade operator in VM
...
- Factoring out parsing of selectors
- Create temp variable holding the receiver of the cascade
selectors
Review URL: https://chromiumcodereview.appspot.com//10796109
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9857 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-24 17:20:49 +00:00
asiva@google.com
ec7f44f025
Create frequently used symbols in the vm isolate
...
- Avoids the need for doing a NewSymbol on these everytime
- saves space as they get shared by isolates
Review URL: https://chromiumcodereview.appspot.com//10783035
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9834 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-24 00:01:50 +00:00
iposva@google.com
7f843b0fc9
- Start using the collected store buffer entries to find
...
old->new references during Scavenge.
Review URL: https://chromiumcodereview.appspot.com//10797021
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9791 260f80e4-7a28-3924-810f-c04153c831b5
2012-07-20 21:41:55 +00:00
hausner@google.com
3aedbb74e8
Better breakpoint placement
...
Instead of using token distance to find the first possible breakpoint
position in a line, use generated code address, so the debugger
breaks before the first call on a source line.
Fix issue 3653
http://code.google.com/p/dart/issues/detail?id=3318
Review URL: https://chromiumcodereview.appspot.com//10686003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@9176 260f80e4-7a28-3924-810f-c04153c831b5
2012-06-27 16:13:49 +00:00
hausner@google.com
f6c776dcbe
Eliminate unary plus with hex literals
...
The spec says unary + is only allowed with integer and floating point literals, not with hex literals. Somebody noticed that the VM accepted
+0x10 as well.
Consequently, the Math.parseInt(str) library function should fail with
a BadNumberFormatException if it is called with a hex number that is preceded by a +.
Fixes issue 1540.
This change exposed that the dart2js core library implementation is
falsely accepting +0xNNN hex numbers. I filed issue 3333.
Review URL: https://chromiumcodereview.appspot.com//10456060
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8177 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-31 22:35:29 +00:00
cshapiro@google.com
36f57531ec
Reject high- and low-surrogates in escaped code points.
...
BUG=3097
Review URL: https://chromiumcodereview.appspot.com//10388179
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7725 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-17 22:57:00 +00:00
asiva@google.com
fe77f95469
Fix for Issue 2367
...
The '\r' character was included in the string literal when parsing integer or double literals. This was resulting in incorrect integer values being created.
Review URL: https://chromiumcodereview.appspot.com//10054027
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6442 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-11 22:07:47 +00:00
iposva@google.com
d8c7e85a30
- Reintroduce a library privacy disabling option.
...
Review URL: https://chromiumcodereview.appspot.com//9594040
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4987 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-05 22:54:02 +00:00
hausner@google.com
4e88231326
Fix bug 1557
...
Better handling of malformed library tags.
TBR=iposva
Review URL: https://chromiumcodereview.appspot.com//9582036
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4912 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-03 00:39:04 +00:00
asiva@google.com
33d2e2fe26
Changes to shrink the token stream representation from two words to one word.
...
On standalone dartium which has about 50000 tokens in the libraries (core, coreimpl, builtin, io etc.) this reduces the heap size by about 180kb. The size of the standalone snapshot buffer reduces by about 72kb.
Also moved the keyword symbol table to the object store so that it does not have to repopulated on every script compilation. Should benefit regular user script load times.
Review URL: https://chromiumcodereview.appspot.com//9462003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4734 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-29 02:46:29 +00:00
hausner@google.com
eff1a31d6f
Fixing bugs: 1612, 1843, 1847
...
- Fix error location when referring to types in object allocation.
- Handle CR/LF correctly at beginning of source.
- Detect duplicate identifier in typedef declaration.
Review URL: https://chromiumcodereview.appspot.com//9466030
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4584 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-25 00:47:06 +00:00
iposva@google.com
f0c1954e9b
Fix issue 732:
...
- Add handling for #resource library tags: Ignore at runtime, they are only used
by the Dart Editor at the moment.
Review URL: https://chromiumcodereview.appspot.com//9431038
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4493 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-22 21:40:07 +00:00
hausner@google.com
b89e03ef16
Placate linux compiler
...
Review URL: https://chromiumcodereview.appspot.com//9349019
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@4000 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-07 16:40:38 +00:00
hausner@google.com
dfee219860
Fix string escape, recognize escaped newline
...
Fix issue 1350 (http://code.google.com/p/dart/issues/detail?id=1350 )
Review URL: https://chromiumcodereview.appspot.com//9346005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3999 260f80e4-7a28-3924-810f-c04153c831b5
2012-02-07 16:37:24 +00:00
srdjan@google.com
9e77768c91
Fix for bug 1229: Unary operator plus is not allowed ... except for literals.
...
Add tests for incorrect literals, e.g. "+ 5".
Added a temporary token kTIGHTADD that represents an ADD not terminated by a whitespace. It is temporary and eliminated in the parser (code generator ot AST do not see it). It is used to recognize correct literals.
Review URL: https://chromiumcodereview.appspot.com//9264051
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3745 260f80e4-7a28-3924-810f-c04153c831b5
2012-01-31 20:05:24 +00:00
hausner@google.com
3ebdf081ca
Set breakpoint at url, line number
...
Add debugger functionality to set breakpoint at given url and line number.
Review URL: https://chromiumcodereview.appspot.com//9240014
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3420 260f80e4-7a28-3924-810f-c04153c831b5
2012-01-18 23:15:56 +00:00
sgjesse@google.com
bf67f24098
Move assert.h/assert.cc from runtime/vm to runtime/platform
...
The purpose of this change is twofold:
1. Source in the bin directory can now use the same assertions as
source in the vm directory. The ASSERT macro used by the code
in runtime/bin was just defined to use assert from the standard
C library.
2. Moving other implementation parts from runtime/vm to
runtime/platform (e.g. classes Monitor and Mutex) for sharing
between runtime/bin and runtime/vm will be easier as these
implementations rely on these assertion macros.
Created two gypi files for the platform directory. One for the
headers and one for the source. The source one is only included
when building the VM library and will be present in libdart.a
when the dart executable is linked.
All the code for asserts is still in the dart namespace.
Also re-arranged the order of includes to be alphabetically in
the files touched.
R=ager@google.com , iposva@google.com
BUG=
TEST=
Review URL: http://codereview.chromium.org//9189003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3335 260f80e4-7a28-3924-810f-c04153c831b5
2012-01-16 12:28:10 +00:00
iposva@google.com
731616c7d3
- Remove support for ">>>" operator.
...
Review URL: http://codereview.chromium.org//9203004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3279 260f80e4-7a28-3924-810f-c04153c831b5
2012-01-13 09:10:48 +00:00
regis@google.com
9f230a34c6
Implement type checking of list literals (issue 220).
...
Remove expose_core_impl flag.
Add tests.
Fix tests.
Cleanup type checking of map literals.
Review URL: http://codereview.chromium.org//8676001
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1809 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-23 19:34:23 +00:00
asiva@google.com
ce606eda7b
Library prefix should be an identifier
...
(we don't yet check that it is not a reserved keyword, that can be done only
after we are able to store the keyword table as a singleton in the vm isolate)
Review URL: http://codereview.chromium.org//8500006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1720 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-21 22:17:41 +00:00
hausner@google.com
8a6a9e645d
Better error handling when scanning library tags
...
Fixes Issue 516
http://code.google.com/p/dart/issues/detail?id=516
#!/dart_bin
##library("foo");
void main() {
print("goodbye");
}
Errors encountered while loading script: '/private/tmp/t.dart': Error: line 2 pos 2: Unrecognized library tag
##library("foo");
^
Review URL: http://codereview.chromium.org//8586052
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1664 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-18 17:50:32 +00:00
dgrove@google.com
4c0f559d23
Initial checkin.
...
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-05 05:20:07 +00:00