Skip to content

register init failed #25335

@richerfu

Description

@richerfu

Zig Version

0.15.1

Steps to Reproduce and Observed Behavior

comptime {
        const init_array = [1]*const fn () callconv(.c) void{&ModuleImpl.module_init};
        @export(&init_array, .{ .linkage = .strong, .name = "init_array", .section = ".init_array" });
}

It worked with arm64 and arm in 0.15.1.

Try to build x86_64-linux-ohos failed in 0.15.1, it worked in 0.14.1.

error: Unimplemented: ExportOptions.section
        @export(&init_array, .{ .linkage = .strong, .name = "init_array", .section = ".init_array" });

Expected Behavior

It should work in 0.15.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugObserved behavior contradicts documented or intended behavior

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions