refactor: split libomf.c into libomf.c and scanomf.c #1767

Merged
merged 2 commits into from Mar 21, 2013

Conversation

Projects
None yet
2 participants
@WalterBright
Owner

WalterBright commented Mar 19, 2013

This isolates knowledge of the lib file format and the omf file format into separate encapsulations.

- return idx;
-}
+unsigned OMFObjSize(const void *base, unsigned length, const char *name);
+void writeOMFObj(OutBuffer *buf, const void *base, unsigned length, const char *name);

This comment has been minimized.

Show comment Hide comment
@MartinNowak

MartinNowak Mar 21, 2013

Member

Can we get a header for the exported scanomf.c functions?

@MartinNowak

MartinNowak Mar 21, 2013

Member

Can we get a header for the exported scanomf.c functions?

This comment has been minimized.

Show comment Hide comment
@WalterBright

WalterBright Mar 21, 2013

Owner

I plan to do libelf.c and libmach.c first before deciding on what the .h file should look like.

@WalterBright

WalterBright Mar 21, 2013

Owner

I plan to do libelf.c and libmach.c first before deciding on what the .h file should look like.

-Ret:
- for (u = 1; u < names.dim; u++)
- free(names[u]);
+ extern void scanOmfObjModule(void*, void (*pAddSymbol)(void*, char*, int), void *, size_t, const char *, Loc loc);

This comment has been minimized.

Show comment Hide comment
@MartinNowak

MartinNowak Mar 21, 2013

Member

Should live in a header.

@MartinNowak

MartinNowak Mar 21, 2013

Member

Should live in a header.

+ extern bool scanOmfLib(void*, void (*pAddObjModule)(void*, char*, void *, size_t), void *, size_t, unsigned);

This comment has been minimized.

Show comment Hide comment
@MartinNowak

MartinNowak Mar 21, 2013

Member

And this one too.

@MartinNowak

MartinNowak Mar 21, 2013

Member

And this one too.

@MartinNowak

This comment has been minimized.

Show comment Hide comment
@MartinNowak

MartinNowak Mar 21, 2013

Member

How does that OmfLib work?
You split an OMF object into multiple objects before writing out the library?

Member

MartinNowak commented Mar 21, 2013

How does that OmfLib work?
You split an OMF object into multiple objects before writing out the library?

@WalterBright

This comment has been minimized.

Show comment Hide comment
@WalterBright

WalterBright Mar 21, 2013

Owner

The omf objects from an input library are all read in and then inserted into the output library.

Owner

WalterBright commented Mar 21, 2013

The omf objects from an input library are all read in and then inserted into the output library.

MartinNowak added a commit that referenced this pull request Mar 21, 2013

Merge pull request #1767 from WalterBright/scanomf
refactor: split libomf.c into libomf.c and scanomf.c

@MartinNowak MartinNowak merged commit 656aba1 into dlang:master Mar 21, 2013

1 check passed

default Pass: 10
Details

@WalterBright WalterBright deleted the WalterBright:scanomf branch Mar 22, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment