Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8181997
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T00:42:39+00:00 2026-06-07T00:42:39+00:00

In js we have a function named Function . An instance of it returns

  • 0

In js we have a function named “Function“.
An instance of it returns a function:

var myfunc = new Function('arg1','arg2','return arg1+arg2');

In that example the variable myfunc contains a function that returns the sum of two given params.

My question is – how is that possible that Function is a function? It can’t be an instance of itself.
And Object is a function too, an instance of Function. But Function is an instance of Object because function are objects.

And I can’t understand how is it possible, it’s an infinity loop…

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T00:42:41+00:00Added an answer on June 7, 2026 at 12:42 am

    The trivial answer is “because ECMA-262 says so”.

    Objects like Function, Object, Array, Date etc. are built–in objects so they aren’t constructed in the usualy way, they just are. The relationship between them, their prototype and their [[Prototype]] is established by the environment in accordance with ECMA-262. So Function inherits from its own prototype (i.e. Function.prototype === Function[[Prototype]]), which inherits from Object.prototype.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a class named MyCart. Class MyCartClass { var $MyCart; function getCart(){ return
I have a jQuery setInterval function named timerIncrement that times out (stops incrementing the
I have a variable named age and a function named AGE. Ignore the problem
I have a function in view.py which returns two variables i.e. a dictionary named
I have a class named toto which I send to a function that does
I have a base class named 'baseScreen' as follows: digient.casino.ui.baseScreen = function() { goog.debug.Logger.getLogger('demo').info('baseScreen');
Suppose we have a shared library named libtest.so, there is one function foo in
I have a function that takes a string object name and I need the
I have a javascript function: string.prototype.startsWith = function(str) { return (this.indexOf(str) === 0); }
I have a javascript object with several properties. The object also contains an instance

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.