# Infer super function call from super

**URL:** <https://es.discourse.group/t/infer-super-function-call-from-super/408>\
**Category:** 💡 Ideas\
**Created:** [July 30, 2020, 4:17am UTC](https://es.discourse.group/t/infer-super-function-call-from-super/408 "2020-07-30T04:17:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![JonathanDW](https://yyz2.discourse-cdn.com/free1/user_avatar/es.discourse.group/jonathandw/32/391_2.png) [@JonathanDW](https://es.discourse.group/u/JonathanDW)\
**Post date:** [July 30, 2020, 4:17am UTC](https://es.discourse.group/t/infer-super-function-call-from-super/408/1 "2020-07-30T04:17:15Z")

</div>

When calling a super function from a child class, I suggest that super should infer the parent super function. Having to call the super function is redundant in most cases. It is already inferred by the constructor so the fact that it is not inferred by the child functions is a little odd.

```javascript
class MyParent {
   protected myFunction(test:string):void {
   }
}

class MyChild extends MyParent {
   myFunction(test:string):void {
      super("test"); //this should infer super.myFunction()
   }
}

```
