Skip to content

Merge common fields of BlobBody and ReadData into a new struct #6768

Closed

Description

@jdm

There's a bunch of overlap between the two structs and the common data just gets passed around a bunch. We should create a ReadMetadata struct, remove BlobData and ReadData, and replace them like so:
fn foo(data: ReadData) becomes fn foo(data: ReadMetadata, blob_contents: Sender<Option<Vec<u8>>>), while fn foo(data: BlobData) becomes fn foo(data: ReadMetadata, blob_contents: Option<Vec<u8>>).

Code: components/script/dom/filereader.rs

Activity

  1. added
    A-content/dom
    E-less-complex
    I-refactor
    on Jul 25, 2015
  2. pr0hin commented on Jul 26, 2015

    @pr0hin
    Contributor

    Hi jdm, I'd like to give this a go.

  3. jdm commented on Jul 26, 2015

    @jdm
    MemberAuthor

    Go for it!

  4. added
    C-assigned
    on Jul 26, 2015
  5. changed the title [-]Merge common fields of BlobData and ReadData into a new struct[/-] [+]Merge common fields of BlobBody and ReadData into a new struct[/+] on Jul 26, 2015
  6. jdm commented on Jul 31, 2015

    @jdm
    MemberAuthor

    Any progress, @r0e?

  7. pr0hin commented on Aug 1, 2015

    @pr0hin
    Contributor

    Yes, sorry, I'm working on it now. Been busy the last few days.

  8. added 6 commits that reference this issue on Aug 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-content/domC-assignedE-less-complexI-refactor

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions