pub struct JavaBackend { /* private fields */ }Expand description
Java code generation backend.
Implementations§
Source§impl JavaBackend
impl JavaBackend
Sourcepub fn mangle_name(&self, name: &str) -> String
pub fn mangle_name(&self, name: &str) -> String
Mangle a name so it does not clash with Java keywords or invalid characters.
Sourcepub fn emit_module(decls: &[LcnfFunDecl]) -> Result<String, String>
pub fn emit_module(decls: &[LcnfFunDecl]) -> Result<String, String>
Compile a slice of LCNF declarations into a complete Java source string.
Sourcepub fn compile_decl(&mut self, decl: &LcnfFunDecl) -> Result<JavaMethod, String>
pub fn compile_decl(&mut self, decl: &LcnfFunDecl) -> Result<JavaMethod, String>
Compile a single LCNF function declaration to a JavaMethod.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for JavaBackend
impl RefUnwindSafe for JavaBackend
impl Send for JavaBackend
impl Sync for JavaBackend
impl Unpin for JavaBackend
impl UnsafeUnpin for JavaBackend
impl UnwindSafe for JavaBackend
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more