Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split rustc into libraries #560

Closed
brson opened this issue Jun 23, 2011 · 11 comments
Closed

Split rustc into libraries #560

brson opened this issue Jun 23, 2011 · 11 comments
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup.

Comments

@brson
Copy link
Contributor

brson commented Jun 23, 2011

Parts of rustc will need to be used outside of the compiler and splitting it up will help improve the design.

One possible division:

  • front - ast, parser, pretty-printer
  • middle - resolver, typechecker, typestate
  • back - trans, link, etc.

creader needs to be somewhere as well. Needs more thought and discussion.

@graydon
Copy link
Contributor

graydon commented Aug 25, 2011

syntax and rustc (middle-and-back) are their own libraries now. I think this is an ok split. closing.

@graydon graydon closed this as completed Aug 25, 2011
@brson brson reopened this Aug 25, 2011
@brson
Copy link
Contributor Author

brson commented Aug 25, 2011

there hasn't actually been a library split yet, just some reorganization

@ghost ghost assigned brson Mar 15, 2012
@brson
Copy link
Contributor Author

brson commented Apr 9, 2012

The rustsyntax crate now contains the parser, pretty-printer and syntax extensions. Probably syntax extensions belong somewhere else eventually.

The metadata module is also a good candidate for extracting into its own library, since it will be needed for dynamic loading and other reflection purposes.

The few frontend passes that remain mostly do extension-like things and probably belong somewhere else eventually.

The directory structure of rustc is a bit weird right now. Technically, rustc is just one .rs file and everything under src/rustc should be under src/librustc.

@sanxiyn
Copy link
Member

sanxiyn commented Mar 29, 2013

Things are under src/librustc now.

@bstrie
Copy link
Contributor

bstrie commented Apr 1, 2013

@sanxiyn Though the division of libraries is the same as of brson's last comment. I think that splitting librustc into more libs would be nice, if only because a small number of big chunks are easier to understand than a single enormous chunk.

@pcwalton
Copy link
Contributor

I don't believe this is backwards incompatible, renominating.

@graydon
Copy link
Contributor

graydon commented May 30, 2013

just a bug, removing milestone/nomination.

@emberian
Copy link
Member

Still relevant

@huonw
Copy link
Member

huonw commented Oct 25, 2013

triage, no changes

@emberian
Copy link
Member

Visiting for triage. No change.

@brson
Copy link
Contributor Author

brson commented Jun 19, 2014

Might as well close this. Everybody knows rustc needs to be refactored.

@brson brson closed this as completed Jun 19, 2014
keeperofdakeys pushed a commit to keeperofdakeys/rust that referenced this issue Dec 12, 2017
kazcw pushed a commit to kazcw/rust that referenced this issue Oct 23, 2018
The official name of the memory intrinsics has changed to `memory.size` and
`memory.grow`, so let's reflect that with our naming as well! Additionally they
have an argument of which memory to operate on with LLVM and must always be zero
currently.
pdietl pushed a commit to pdietl/rust that referenced this issue Apr 23, 2020
ZuseZ4 pushed a commit to EnzymeAD/rust that referenced this issue Mar 7, 2023
celinval added a commit to celinval/rust-dev that referenced this issue Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup.
Projects
None yet
Development

No branches or pull requests

7 participants