ceylon/ceylon-compiler — Issue #371: Boxing issue with String and foo[i..j] syntax
Author: gavinking
Created: 2012-02-09 09:17:17+00:00
State: open
Labels: BUG, high priority

```
String parseHost(String url, Integer start){
if (exists index = url.terminal(start)
.firstCharacterOccurrence(`/`)) {
return url[start..index-1];
}
else {
throw ;//"Invalid Host: " + url;
}
}
```

I get:

```
/Users/gavin/runtime-EclipseApplication/url/source/url.ceylon:13: inconvertible types
found : java.lang.String
required: ceylon.language.Ranged
return url[start..index-1];
^
```