Commit Graph

35 Commits

Author SHA1 Message Date
floitsch@google.com ed938af868 Rename new Uri.fromString to Uri.parse.
Review URL: https://codereview.chromium.org//12052038

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17562 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-24 13:26:18 +00:00
ager@google.com 3c8d8827c0 Deal with extension loading from packages.
The issue is bad interplay with package and dart-ext URIs.
dart-ext URIs overwrite the package URI which makes us lose
the package URI path components. This change resolves
all the way to a file path for dart-ext URIs if the base
URI is a package URI.

R=whesse@google.com
BUG=dartbug.com/6264

Review URL: https://codereview.chromium.org//11308170

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15272 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-23 07:03:15 +00:00
floitsch@google.com 8e6f238f86 a === b -> identical(a, b)
Replace === null with == null.

BUG=http://dartbug.com/6380

Review URL: https://codereview.chromium.org//11361190

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14794 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-12 17:19:58 +00:00
gram@google.com 96016f9034 Fix library syntax
Review URL: https://codereview.chromium.org//11368124

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14701 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-08 18:41:58 +00:00
iposva@google.com 9cb8c71871 Fix bug 4534:
- Only drop the leading "/" on Windows if a leading slash is in the path.
Review URL: https://codereview.chromium.org//11368114

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14609 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-07 01:05:09 +00:00
iposva@google.com 338e6a6806 Fix dartbug.com/3424:
- Remove bogus return type.
Review URL: https://chromiumcodereview.appspot.com//10920049

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11728 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 22:07:51 +00:00
ager@google.com 178100ded4 Move print to corelib.
Allow embedder customization in the VM through a static field that can
be set by the embedder.

Mark failing test that is unrelated to this change. The VM does not
like when you import dart:core explicitly and tells you there both
'dart:core' and 'dart:core' define 'print'.

R=ajohnsen@google.com,iposva@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10887024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11603 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 11:31:30 +00:00
ager@google.com 8accd53776 Move exit from the builtin library to dart:io.
R=sgjesse@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10879033

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11217 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-23 08:50:22 +00:00
ahe@google.com 1e0c2471a5 Changed default Uri constructor to Uri.fromComponents(), new default constructor is Uri.fromString(). This is to avoid new Uri('http://www.google.com') resulting in Uri with scheme='http://www.google.com'.
Committing on behalf of: Alexander Aprelev <aprelev@gmail.com>

BUG=dart-3348
TEST=new Uri('http://www.google.com') is the same as new Uri.fromString('http://www.google.com') same as new Uri.fromComponents(scheme:'http', domain:'www.google.com')

Review URL: https://chromiumcodereview.appspot.com//10850015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@10168 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-02 13:48:30 +00:00
turnidge@google.com 05b5d44b0e spawnUri. Take two. This time I'll wait for Anton before committing :-).
See original change 7756 for description.
Review URL: https://chromiumcodereview.appspot.com//10407042

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7917 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-23 18:32:51 +00:00
turnidge@google.com 76d4586dea Revert my last change.
Review URL: https://chromiumcodereview.appspot.com//10332257

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7757 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-18 18:35:04 +00:00
turnidge@google.com 6a8c82db83 Implement spawnUri from dart:isolate. This function allows us to
launch an isolate running a different script.  Finally.

Reviewers: This isn't as hard to review as it looks.  Dive right in!

Siggi: Take a look at my test status file changes and make sure I'm
excluding the right stuff.

Much of the churn in the CL comes from moving ownership of the
import_map.  It used to be set per-library and is now set per-isolate.
This caused a lot of superficial diffs.

DART EMBEDDING API CHANGES:

- Dart_IsolateCreateCallback now takes a script_uri and main argument
  instead of a name_prefix argument.  The script_uri argument allows
  the callback to launch different scripts.  The main argument is used
  in creating the isolate debug name.

- Dart_CreateIsolate now takes script_uri and main arguments.  These
  are used to build the isolate's debug name.

- Dart_LibraryTagHandler, Dart_LoadScript, and Dart_LoadLibrary no
  longer take an import_map.

- Added Dart_SetImportMap.

- Added Dart_RootLibrary to provide access to the root library for the
  current isolate.

OTHER STUFF

Add a couple of tests for spawnUri -- the existing tests assume that
scripts end in a .js suffix which isn't going to work out for us.

Changed how the debug name for isolates get built a bit.

Refactored bin/main.cc a bit.  Fixed some problems with error handling
while creating isolates.

Minor refactoring in builtin.dart to always pass is_windows rather
than relying on it being squirreled away.
Review URL: https://chromiumcodereview.appspot.com//10386107

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7756 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-18 18:22:10 +00:00
hausner@google.com 6fece3e398 Fix tests in language suite: eliminate String +
The language suite runs clean without String + after this change.

string_concat_test.dart is obsolete, removed.
Review URL: https://chromiumcodereview.appspot.com//10383238

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7745 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-18 15:33:05 +00:00
asiva@google.com 4f105f9d0b Resubmit change 7506.
Review URL: https://chromiumcodereview.appspot.com//10387061

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7511 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-10 19:17:37 +00:00
iposva@google.com 1829b6328a - Fix the no_snapshot build.
Review URL: https://chromiumcodereview.appspot.com//10389072

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7505 260f80e4-7a28-3924-810f-c04153c831b5
2012-05-10 18:16:46 +00:00
mattsh@google.com cb829918ed added package_root flag to vm
BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com//10134015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@7092 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-27 17:23:00 +00:00
regis@google.com f955de9bc0 Throw a type error in production mode when the type of the type test is not
declared (issue 2571).
Add test.
Delete bad negative test now covered by new test.
Update status files of different compilers.
Review URL: https://chromiumcodereview.appspot.com//10035058

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6754 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-19 17:01:28 +00:00
iposva@google.com cef84bd895 - Update the style of switch statement.
Review URL: https://chromiumcodereview.appspot.com//10083042

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6680 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-18 11:00:33 +00:00
whesse@google.com 7b9880570d Refactor URI processing of native extensions directive #import("dart-ext:foo").
BUG=
TEST=standalone/io/TestExtensionsTest

Review URL: https://chromiumcodereview.appspot.com//10103031

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6674 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-18 09:58:01 +00:00
rnystrom@google.com c47bd07592 Fix merge bug.
Review URL: https://chromiumcodereview.appspot.com//10020049

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6435 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-11 20:27:57 +00:00
rnystrom@google.com eea5e1a621 Fix "package:" stuff on Windows and skip tests on dart2js since it doesn't support it yet.
Review URL: https://chromiumcodereview.appspot.com//10052021

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6431 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-11 20:14:08 +00:00
rnystrom@google.com 93e45629c9 Add support for importing using "package:" to the standalone VM.
Review URL: https://chromiumcodereview.appspot.com//10034001

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@6428 260f80e4-7a28-3924-810f-c04153c831b5
2012-04-11 19:40:51 +00:00
iposva@google.com de4e574ac3 - Make the URI resolution methods used by the tag handler private.
Review URL: https://chromiumcodereview.appspot.com//9845040

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5921 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-28 01:21:04 +00:00
whesse@google.com 3b7099b7e2 Change lookup path for Dart native extensions shared libraries.
BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com//9694045

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5524 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-15 15:49:57 +00:00
iposva@google.com 69eafdd3cf - Win: Disable logging output during script URI resolution.
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5143 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-08 00:19:39 +00:00
iposva@google.com 8c3715be59 - Win: Remove leading / from file path.
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5141 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-08 00:08:21 +00:00
iposva@google.com e3a8f10c52 - D:\rive\letters
Review URL: https://chromiumcodereview.appspot.com//9608028

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5140 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-08 00:02:17 +00:00
iposva@google.com 67b02b441d - Proper URI resolution when loading scripts from the standalone binary.
Review URL: https://chromiumcodereview.appspot.com//9614006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5135 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-07 22:57:57 +00:00
ager@google.com 4efd1f98fa Split dart:builtin into dart:builtin and dart:io.
- dart:builtin is implicitly imported.
- dart:io has to be explicitly imported.

I will update the macos and windows stable test binaries when we
are happy with the solution.

R=iposva@google.com
BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com//9254026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@3537 260f80e4-7a28-3924-810f-c04153c831b5
2012-01-24 07:36:59 +00:00
sgjesse@google.com d7c8c1f1e4 Fix a number of issues with the process handling
1. Ignore the signal SIGPIPE on Linux and Mac OS

When reading from or writing to a closed pipe the signal SIGPIPE
is raised. The default handling of this is to terminate the
program. When signal SIGPIPE is ignored the read and write
returns EPIPE.

2. Wrong return type for stdio getter

3. When there is an error on a socket mark it as closed

4. Mark the pipe used for process exit status as a one way pipe

5. Add tests to test stdin, stdout and stderr in Dart scripts

R=ager@google.com

BUG=dart:536, dart:454
TEST=

Review URL: http://codereview.chromium.org//8662006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1793 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-23 14:49:18 +00:00
asiva@google.com 9f49e2bf74 Implement automatic loading of dart:core_native_fields library
with predefined classes having native fields.
Classes that need native fields in them can import this library and
extend these predefined classes.
Review URL: http://codereview.chromium.org//8537023

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1629 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-17 21:04:43 +00:00
sgjesse@google.com 04bc611751 Handle stdin/stdout/stderr on Windows
Create handle objects for stdin/stdout/stderr. For Mac OS and
Linus the file descriptor numbers are used but on Windows the
handles are wrapped in an object.

The system handles for stdin/stdout/stderr on Windows does not
support overlapped IO. To mittigate this the write calls are
performed synchronously and the read calls are preformed in a
thread which posts the result through the completion potr where
it is handled as if it originated from overlapped IO through the
completion port. For now each call to read starts a new thread.

R=ager@google.com

BUG=
TEST=

Review URL: http://codereview.chromium.org//8574002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1533 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-15 13:19:07 +00:00
sgjesse@google.com 38b2b0d5d8 Provide access to stdin, stdout and stderr
R=ager@google.com, iposva@google.com

BUG=dart:402
TEST=

Review URL: http://codereview.chromium.org//8525002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@1456 260f80e4-7a28-3924-810f-c04153c831b5
2011-11-11 11:45:53 +00:00
rchandia@google.com 035fdaa49d Added builtin native call to exit the running vm
Total uses exit(int) to signal whether to stop or restart

R=iposva@google.com
BUG=
TEST=

Review URL: http://codereview.chromium.org//8317006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@893 260f80e4-7a28-3924-810f-c04153c831b5
2011-10-28 15:32:33 +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