Alien-LibJIT
view release on metacpan or search on metacpan
libjit/jitplus/jit-plus-value.cpp view on Meta::CPAN
/*
* jit-plus-value.cpp - C++ wrapper for JIT values.
*
* Copyright (C) 2004 Southern Storm Software, Pty Ltd.
*
* This file is part of the libjit library.
*
* The libjit library is free software: you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* as published by the Free Software Foundation, either version 2.1 of
* the License, or (at your option) any later version.
*
* The libjit library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with the libjit library. If not, see
* <http://www.gnu.org/licenses/>.
*/
#include <jit/jit-plus.h>
/*@
The @code{jit_value} class provides a C++ counterpart to the
@code{jit_value_t} type. Values normally result by calling methods
on the @code{jit_function} class during the function building process.
@xref{Values}, for more information on creating and managing values.
@defop Constructor jit_value jit_value ()
Construct an empty value.
@end defop
@defop Constructor jit_value jit_value (jit_value_t @var{value})
Construct a value by wrapping up a raw C @code{jit_value_t} object.
@end defop
@defop Constructor jit_value jit_value (const jit_value& @var{value})
Create a copy of @var{value}.
@end defop
@defop Destructor jit_value ~jit_value ()
Destroy the C++ value wrapper, but leave the underlying raw C
value alone.
@end defop
@defop Operator jit_value {jit_value& operator=} (const jit_value& @var{value})
Copy @code{jit_value} objects.
@end defop
@deftypemethod jit_value jit_value_t raw () const
Get the raw C @code{jit_value_t} value that underlies this object.
@end deftypemethod
@deftypemethod jit_value int is_valid () const
Determine if this @code{jit_value} object contains a valid raw
C @code{jit_value_t} value.
@end deftypemethod
@deftypemethod jit_value int is_temporary () const
@deftypemethodx jit_value int is_local () const
@deftypemethodx jit_value int is_constant () const
Determine if this @code{jit_value} is temporary, local, or constant.
@end deftypemethod
@deftypemethod jit_value void set_volatile ()
@deftypemethodx jit_value int is_volatile () const
Set or check the "volatile" state on this value.
@end deftypemethod
@deftypemethod jit_value void set_addressable ()
@deftypemethodx jit_value int is_addressable () const
Set or check the "addressable" state on this value.
@end deftypemethod
@deftypemethod jit_value jit_type_t type () const
Get the type of this value.
@end deftypemethod
@deftypemethod jit_value jit_function_t function () const
@deftypemethodx jit_value jit_block_t block () const
@deftypemethodx jit_value jit_context_t context () const
Get the owning function, block, or context for this value.
@end deftypemethod
@deftypemethod jit_value jit_constant_t constant () const
@deftypemethodx jit_value jit_nint nint_constant () const
( run in 0.705 second using v1.01-cache-2.11-cpan-97f6503c9c8 )