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 8313231
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T20:25:19+00:00 2026-06-08T20:25:19+00:00

After doing much reading on invokeDynamic, i am still a bit confused.One repeating theme

  • 0

After doing much reading on invokeDynamic, i am still a bit confused.One repeating theme seems to be how Clojure doesn’t really need it, or at least need it less than other dynamic language implementations on the JVM (Jruby,JPython,Groovy etc.).I didn’t understand all the details but it seems that having type annotations is the main reason, which simply eliminate the dynamic dispatch problem.

1- Is it safe to describe invoke-dynamic as way to efficiently implement complex method dispatch scenarios ? (is there more to it ?)

2- Shouldn’t having a jit eliminate the need for invoke-dynamic ? The problem seems to arise from the lack of runtime type informations and a jit should have this information.

3-JRuby seems to booth have a jit and use invokdynamic,Why ?

  • 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-08T20:25:21+00:00Added an answer on June 8, 2026 at 8:25 pm

    The main reason is that Clojure doesn’t “need” invokedynamic is that it doesn’t actually do that much dynamic dispatch. In particular:

    • Whenever Clojure has enough type information (e.g. calling a Java class with a type hint) it does direct method dispatch
    • All functions are called using interface method dispatch (via IFn)
    • The compiler does intelligent inlining in many cases (e.g. primitive functions) avoiding any kind of dispatch
    • Protocol functions are called through interface method dispatch

    This covers the vast majority of dispatch cases.

    There are of course a few dispatch cases where invokedynamic could prove useful (e.g. multimethods) and it could probably be used to optimise some other parts of Clojure (e.g. var lookup) so Clojure will be able to get some benefits.

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

Sidebar

Related Questions

After doing a project with WPF and getting very much attached to it's excellent
After doing a long search on stackoverflow i didn't find any one talked about
After doing some reading about the Module Pattern, I've seen a few ways of
I've been doing some reading on mysqli_real_escape_string(), and, after getting my content properly escaped,
after doing some preliminary searching, I was not able to find much information on
After doing a set , when i try to get a object from memcached,
After doing the following test: for( i = 0; i < 3000000; i++ )
After doing lot of research in Google, I found this program: #include <stdio.h> int
After doing some Core animations using: [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:0.5]; [self setAffineTransform:CGAffineTransformIdentity]; [UIView
After doing a subversion merge with a co-worker, my VSeWSS project no longer build

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.