various: translation resources from cg backend
Extend `CodegenBackend` trait with a function returning the translation resources from the codegen backend, which can be added to the complete list of resources provided to the emitter. Signed-off-by: David Wood <david.wood@huawei.com>
This commit is contained in:
parent
3e14bba40c
commit
984945a117
1 changed files with 4 additions and 0 deletions
|
@ -103,6 +103,10 @@ pub struct GccCodegenBackend {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl CodegenBackend for GccCodegenBackend {
|
impl CodegenBackend for GccCodegenBackend {
|
||||||
|
fn locale_resource(&self) -> &'static str {
|
||||||
|
crate::DEFAULT_LOCALE_RESOURCE
|
||||||
|
}
|
||||||
|
|
||||||
fn init(&self, sess: &Session) {
|
fn init(&self, sess: &Session) {
|
||||||
if sess.lto() != Lto::No {
|
if sess.lto() != Lto::No {
|
||||||
sess.emit_warning(LTONotSupported {});
|
sess.emit_warning(LTONotSupported {});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue