# Internal Error: Loop through function \`.ResolveExpression\`

**URL:** https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672
**Category:** Elements Bugs
**Created:** [June 16, 2019, 12:59pm UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672 "2019-06-16T12:59:57Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![dbroggi](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/d/df788c/32.png) [@dbroggi](https://talk.remobjects.com/u/dbroggi)
#### Post date: [June 16, 2019, 12:59pm UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/1 "2019-06-16T12:59:57Z")

</div>

**IDE:** _Visual Studio X/Fire_  
**Version:** _10.0.0.2413 (develop)_  
**Target** (If relevant): _OSX_  
**Description** :  
This is a reduction that preserved a stack overflow.

**Expected Behavior** :  
Compiler Errors.  
**Actual Behavior** :  
Stack overflow.  
**Steps** :

```auto
struct S {}

protocol P {}

extension S: ExpressibleByStringLiteral {
   typealias StringLiteralType = S
   public init(stringLiteral value: S) {
       self = value
   }
}

extension P {
    public func foo(separator: S = "") {}
}

```

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [June 17, 2019, 4:40am UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/2 "2019-06-17T04:40:04Z")

</div>

Thanks, logged as [bugs://82795](https://www.remobjects.com/portal/bugs/?id=82795)

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [June 17, 2019, 9:19am UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/3 "2019-06-17T09:19:03Z")

</div>

[bugs://82795](https://www.remobjects.com/portal/bugs/?id=82795) got closed with status fixed.

---

<div class="post-metadata">

### Author: ![dbroggi](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/d/df788c/32.png) [@dbroggi](https://talk.remobjects.com/u/dbroggi)
#### Post date: [August 30, 2019, 3:47pm UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/4 "2019-08-30T15:47:03Z")

</div>

Although this was fixed for string literals, I just noticed that this occurs similarly for boolean and integer literals in `10.0.0.2433 (develop)`, when a type conforms to the literal protocol with itself as its literal type.

Oh, the things one finds when trying to build the Swift stdlib in Silver.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [August 30, 2019, 5:45pm UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/5 "2019-08-30T17:45:31Z")

</div>

[bugs://82795](https://www.remobjects.com/portal/bugs/?id=82795) got reopened.

---

<div class="post-metadata">

### Author: ![RemObjectsSoftware](https://talk.remobjects.com/user_avatar/talk.remobjects.com/remobjectssoftware/32/15947_2.png) [@RemObjectsSoftware](https://talk.remobjects.com/u/RemObjectsSoftware)
#### Post date: [September 4, 2019, 8:04am UTC](https://talk.remobjects.com/t/internal-error-loop-through-function-resolveexpression/19672/6 "2019-09-04T08:04:30Z")

</div>

[bugs://82795](https://www.remobjects.com/portal/bugs/?id=82795) got closed with status fixed.
