Skip to content
This repository was archived by the owner on Nov 13, 2026. It is now read-only.

Refactor NodeFactory - #1576

Merged
MichalStrehovsky merged 2 commits into
dotnet:masterfrom
MichalStrehovsky:nodeFactory
Jul 24, 2016
Merged

MichalStrehovsky merged 2 commits into
dotnet:masterfrom
MichalStrehovsky:nodeFactory

Conversation

@MichalStrehovsky

@MichalStrehovsky MichalStrehovsky commented Jul 24, 2016 •

Copy link
Copy Markdown
Member

There are several node kinds that will be different depending on the compilation backend. Factor them out into separate classes to remove usage of isCppCodegen.

The base NodeFactory is only allowed to do tasks that are common across codegens now.

We might want a TestNodeFactory in the future for unit testing.

I'll follow up with splitting NodeFactory into one more abstract layer (to e.g. make AttachToDependecyGraph abstract and to take out things like HelperEntrypoint(...)) but for that I need to have a look at how this is used on the TFS side.

I'm also deleting the SingleArgumentJumpThunk. I would need to build abstraction for it, but since it's not used, I don't see the point.

There are several node kinds that will be different depending on the
compilation backend. Factor them out into separate classes to remove
usage of `isCppCodegen`.

The base `NodeFactory` is only allowed to do tasks that are common
across codegens now.

We might want a `TestNodeFactory` in the future for unit testing.

I'll follow up with splitting `NodeFactory` into one more abstract layer
(to e.g. make `AttachToDependecyGraph` abstract and to take out things
like `HelperEntrypoint(...)`).
This is unused and it's an assembly stub referenced from `NodeFactory`,
hence verboten.
@jkotas

jkotas commented Jul 24, 2016

Copy link
Copy Markdown
Member

👍

@MichalStrehovsky

Copy link
Copy Markdown
Member Author

Cc @nattress

@MichalStrehovsky
MichalStrehovsky merged commit c7f71d2 into dotnet:master Jul 24, 2016
@MichalStrehovsky
MichalStrehovsky deleted the nodeFactory branch July 24, 2016 16:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants