Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Closure type

  1. Sep 23, 2005 #1

    Hurkyl

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    What is a "closure type"?

    I first encountered it by looking at the source of the uBLAS package from boost.org -- it's essentially an implementation of the BLAS using expression templates.

    I noticed that a lot of the classes have a nested typedef called "closure_type" (and a "const_closure_type"), and I've never heard of such a thing.

    Also, a couple of the classes define a "same_closure" member function which simply tests for identity. For example, from the "scalar_value" class:
    Code (Text):

            bool same_closure (const scalar_value &sv) const {
                return this == &sv;    // self closing on instances value
            }
     
    And I haven't yet managed to discover the purpose of such a thing by looking through the source code, nor by googling for "closure type". (I get hits on closure type, but not enough info to infer what such a thing is, and the point of it)

    Does anyone here know?
     
  2. jcsd
  3. Sep 25, 2005 #2
    Because it's a non-standard coding to establish parameters to terminate an argument.
     
  4. Sep 25, 2005 #3

    Hurkyl

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    Could you say that again?
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Closure type
  1. Entry type (Replies: 3)

  2. How do i type in (Replies: 2)

Loading...