Skip to content

wit-smith generates wit with the same name on includes #2191

@jsturtevant

Description

@jsturtevant

doing some more testing and was running wit-smit like:

while RUST_BACKTRACE=1 cargo run wit-smith <(head -c 2048 /dev/urandom | tee seed.file) -t -vv ; do :; done

This will eventually give you:

error: The raw data is not of the correct format to construct this type

You can then use the seed in seed.file to reproduce the error. I tracked it down to generating a package like:

 world %xxxxx {
    import %name: interface {
    resource %xx {
    }

    type %l = option<%xx>;

    }
    include %zx;
    }

    world %zx {
    import %name: func(%name: string, %xx: u16, %xhnd: tuple<error-context, char, result<f32>, s16, list<result, 4>, s8>, %name3: s8, %name4: string, %x: u32, %name6: list<s16>, %name7: u16, %name8: f32, %name9: error-context);
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions