Implement the machinery to create a TargetIsa.
Add an isa::lookup() function which serves as a target registry for creating Box<TargetIsa> trait objects. An isa::Builder makes it possible to confugure the trait object before it is created.
This commit is contained in:
@@ -211,6 +211,7 @@ def gen_group(sgrp, fmt):
|
||||
"""
|
||||
byte_size = layout_group(sgrp)
|
||||
|
||||
fmt.line('#[derive(Clone)]')
|
||||
fmt.doc_comment('Flags group `{}`.'.format(sgrp.name))
|
||||
with fmt.indented('pub struct Flags {', '}'):
|
||||
fmt.line('bytes: [u8; {}],'.format(byte_size))
|
||||
|
||||
Reference in New Issue
Block a user