Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strings.concatAll and .join crashes if list contains non-string elements #399

Closed
DartBot opened this issue Nov 9, 2011 · 3 comments
Closed
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.

Comments

@DartBot
Copy link

DartBot commented Nov 9, 2011

This issue was originally filed by [email protected]


test-concatall.dart:
main() => Strings.concatAll([1]);

~/projects/dart/dart % dart test-concatall.dart
./vm/object.h:2473: error: expected: IsNull() || IsString()
zsh: abort dart test-concatall.dart

stack trace:

­0 0x93148332 in __kill ()

­1 0x93147932 in kill$UNIX2003 ()

­2 0x96a8ec0c in abort ()

­3 0x000e3b55 in dart::DynamicAssertionHelper::Fail (this=0xbfffeaa4, format=0x198f8c "expected: %s") at /Users/olov/projects/dart/dart/runtime/vm/assert.cc:39

­4 0x000c578a in dart::String::operator^= (this=0xbfffefd4, value=0x2) at object.h:2473

­5 0x0012c24f in dart::String::ConcatAll (strings=@0xbfffefcc, space=dart::Heap::kNew) at /Users/olov/projects/dart/dart/runtime/vm/object.cc:5886

­6 0x000da8dd in dart::DN_HelperStrings_concatAll (arguments=0xbffff1f4) at /Users/olov/projects/dart/dart/runtime/lib/string.cc:162

­7 0x000daae7 in dart::DN_Strings_concatAll (args=0xbffff1f4) at /Users/olov/projects/dart/dart/runtime/lib/string.cc:159

­8 0x00440162 in ?? ()

­9 0x0060151c in ?? ()

­10 0x00600b94 in ?? ()

­11 0x006009b7 in ?? ()

­12 0x00600393 in ?? ()

­13 0x0060007d in ?? ()

­14 0x0010be65 in dart::DartEntry::InvokeStatic (function=@0x995778, arguments=@0xbffff3c0, optional_arguments_names=@0x995780) at /Users/olov/projects/dart/dart/runtime/vm/dart_entry.cc:83

­15 0x000bef2d in dart::InvokeStatic (function=@0x995778, args=@0xbffff3c0, result=0xbffff3dc) at /Users/olov/projects/dart/dart/runtime/vm/dart_api_impl.cc:985

­16 0x000c113d in Dart_InvokeStatic (library_in=0x8cca10, class_name_in=0x8cca18, function_name_in=0x8cca14, number_of_arguments=0, arguments=0x0) at /Users/olov/projects/dart/dart/runtime/vm/dart_api_impl.cc:1096

­17 0x00002d58 in main (argc=2, argv=0xbffffaec) at /Users/olov/projects/dart/dart/runtime/bin/main.cc:229

@DartBot
Copy link
Author

DartBot commented Nov 9, 2011

This comment was originally written by [email protected]


Added Area-VM, Triaged labels.

@lexprfuncall
Copy link

Should be fixed by http://codereview.chromium.org//8455004

An unhandled exception has been thrown
Illegal argument(s): 1
 0. Function: 'StringBase._concatAll@924b4b8' url: 'bootstrap_impl' line:2366 col:1
 1. Function: 'StringBase.concatAll' url: 'bootstrap_impl' line:2361 col:22
 2. Function: 'Strings.concatAll' url: 'bootstrap' line:2393 col:32
 3. Function: '::.main' url: '/tmp/crash.dart' line:1 col:28


Added Fixed label.

@DartBot
Copy link
Author

DartBot commented Nov 10, 2011

This comment was originally written by [email protected]


That works fine, thanks!

I noticed that the exception contains 'Illegal argument(s): null' when the type-checker is enabled, not sure
if that's intended or not:
~/projects/dart/dart % dart --enable-type-checks test-concatall.dart
An unhandled exception has been thrown
Illegal argument(s): null
 0. Function: 'StringBase._concatAll@924b4b8' url: 'bootstrap_impl' line:2348 col:1
 1. Function: 'StringBase.concatAll' url: 'bootstrap_impl' line:2343 col:22
 2. Function: 'Strings.concatAll' url: 'bootstrap' line:2393 col:32
 3. Function: 'main' url: '/Users/olov/projects/dart/dart/test-concatall.dart' line:1 col:28

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.
Projects
None yet
Development

No branches or pull requests

2 participants