Boost logo

Boost Users :

Subject: Re: [Boost-users] translate C-code into objects
From: Nathan Ridge (zeratul976_at_[hidden])
Date: 2011-07-31 00:41:45


> phoenix is some library to create lambda functions.
> This is not what I need.
> I want to get objects out, which I can later work on.

What sort of "work" do you want to do with these objects?
 
Phoenix *is* a library that creates objects representing
pieces of C++ code - these objects can then be "called"
(operator()) to execute the code they represent.
 
For example, the phoenix expression
 
if_(ref(x) > 5)
[
    std::cout << ref(x)
]
 
represents an object that, when called, executes the code
 
if (x > 5)
{
    std::cout << x;
}
 
(where x is an already-declared variable in your program).

Whether or not Phoenix is suitable for you depends on what
you want to do with these objects.
 
Regards,
Nate.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net