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

Add links for arena and interning. #1868

Merged
merged 3 commits into from
Jan 29, 2024
Merged

Conversation

Arthur-Milchior
Copy link
Contributor

I suspect that people who don't already know about arenas may be interested in the wikipedia page. It may not be the best material on this topic, but I could not find anything that is specific to the arena used by rustc, and this is still a good first approach.

I also copied the link about interning from overview to memory, as the reader may have forgotten that interning was already discussed previously. Admittedly, the wikipedia page is called string interning, but it mentions "Objects other than strings can be interned.", and still explains the idea in a useful manner.

I suspect it may also be useful to link to
https://en.wikipedia.org/wiki/Hash_consing , as it seems the standard way to ensure that each tree (in this case, the AST of a type) is unique in memory. Except that I don't know whether it's actually what Rust uses.

I suspect that people who don't already know about arenas may be interested in
the wikipedia page. It may not be the best material on this topic, but
I could not find anything that is specific to the arena used by rustc, and this
is still a good first approach.

I also copied the link about interning from overview to memory, as the reader
may have forgotten that interning was already discussed previously.  Admittedly,
the wikipedia page is called string interning, but it mentions "Objects other
than strings can be interned.", and still explains the idea in a useful manner.

I suspect it may also be useful to link to
https://en.wikipedia.org/wiki/Hash_consing , as it seems the standard way to
ensure that each tree (in this case, the AST of a type) is unique in
memory. Except that I don't know whether it's actually what Rust uses.
src/memory.md Outdated Show resolved Hide resolved
src/overview.md Outdated Show resolved Hide resolved
@JohnTitor JohnTitor merged commit 9f9c9d2 into rust-lang:master Jan 29, 2024
1 check passed
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Feb 12, 2024
Update books

## rust-lang/edition-guide

1 commits in baafacc6d8701269dab1e1e333f3547fb54b5a59..76bd48a273a0e0413a3bf22c699112d41497b99e
2024-02-10 20:50:34 UTC to 2024-02-10 20:50:34 UTC

- Set up scaffolding for 2024 (rust-lang/edition-guide#288)

## rust-lang/reference

4 commits in a0b119535e7740f68494c4f0582f7ad008b00ccd..8227666de13f6e7bb32dea9dc42e841adb5ce4b7
2024-02-12 03:04:15 UTC to 2024-01-30 20:10:53 UTC

- Fix a typo in external-blocks.md (rust-lang/reference#1467)
- Fix syntax in `'static lifetime elision` section of `lifetime-elision.md` (rust-lang/reference#1463)
- Fix markdown backslash for FLOAT_LITERAL (rust-lang/reference#1464)
- C string literal expressions (rust-lang/reference#1457)

## rust-lang/rust-by-example

5 commits in 179256a445d6144f5f371fdefb993f48f33978b0..e188d5d466f7f3ff9f1d518393235f4fe951be46
2024-02-07 17:16:00 UTC to 2024-01-31 17:34:10 UTC

- Update macros.md (rust-lang/rust-by-example#1815)
- Update borrow.md (rust-lang/rust-by-example#1814)
- Fixes the bug: rust-lang/rust-by-example#1721 (rust-lang/rust-by-example#1811)
- std_misc/process/pipe.md: Fix typo in pangram string (rust-lang/rust-by-example#1809)
- Add expected error behavior into docs (rust-lang/rust-by-example#1810)

## rust-lang/rustc-dev-guide

9 commits in ec287e332777627185be4798ad22599ffe7b84aa..1f30cc7cca9a3433bc1872abdc98960b36c21ca0
2024-02-11 05:36:15 UTC to 2024-01-29 19:49:51 UTC

- fix sentence (rust-lang/rustc-dev-guide#1882)
- Some updates for recent diagnostics changes. (rust-lang/rustc-dev-guide#1883)
- Rename occurrences of 'delay_span_bug' to 'span_delayed_bug' (rust-lang/rustc-dev-guide#1881)
- Update for upcoming markdown changes. (rust-lang/rustc-dev-guide#1880)
- Update uses of renamed BoxMeUp to PanicPayload (rust-lang/rustc-dev-guide#1878)
- Add links for arena and interning. (rust-lang/rustc-dev-guide#1868)
- Improving macro expansion section (rust-lang/rustc-dev-guide#1875)
- Replace letters by foo, bar and buz in lexing example (rust-lang/rustc-dev-guide#1870)
- Fix some broken links (rust-lang/rustc-dev-guide#1877)
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Feb 12, 2024
Update books

## rust-lang/edition-guide

1 commits in baafacc6d8701269dab1e1e333f3547fb54b5a59..76bd48a273a0e0413a3bf22c699112d41497b99e
2024-02-10 20:50:34 UTC to 2024-02-10 20:50:34 UTC

- Set up scaffolding for 2024 (rust-lang/edition-guide#288)

## rust-lang/reference

4 commits in a0b119535e7740f68494c4f0582f7ad008b00ccd..8227666de13f6e7bb32dea9dc42e841adb5ce4b7
2024-02-12 03:04:15 UTC to 2024-01-30 20:10:53 UTC

- Fix a typo in external-blocks.md (rust-lang/reference#1467)
- Fix syntax in `'static lifetime elision` section of `lifetime-elision.md` (rust-lang/reference#1463)
- Fix markdown backslash for FLOAT_LITERAL (rust-lang/reference#1464)
- C string literal expressions (rust-lang/reference#1457)

## rust-lang/rust-by-example

5 commits in 179256a445d6144f5f371fdefb993f48f33978b0..e188d5d466f7f3ff9f1d518393235f4fe951be46
2024-02-07 17:16:00 UTC to 2024-01-31 17:34:10 UTC

- Update macros.md (rust-lang/rust-by-example#1815)
- Update borrow.md (rust-lang/rust-by-example#1814)
- Fixes the bug: rust-lang/rust-by-example#1721 (rust-lang/rust-by-example#1811)
- std_misc/process/pipe.md: Fix typo in pangram string (rust-lang/rust-by-example#1809)
- Add expected error behavior into docs (rust-lang/rust-by-example#1810)

## rust-lang/rustc-dev-guide

9 commits in ec287e332777627185be4798ad22599ffe7b84aa..1f30cc7cca9a3433bc1872abdc98960b36c21ca0
2024-02-11 05:36:15 UTC to 2024-01-29 19:49:51 UTC

- fix sentence (rust-lang/rustc-dev-guide#1882)
- Some updates for recent diagnostics changes. (rust-lang/rustc-dev-guide#1883)
- Rename occurrences of 'delay_span_bug' to 'span_delayed_bug' (rust-lang/rustc-dev-guide#1881)
- Update for upcoming markdown changes. (rust-lang/rustc-dev-guide#1880)
- Update uses of renamed BoxMeUp to PanicPayload (rust-lang/rustc-dev-guide#1878)
- Add links for arena and interning. (rust-lang/rustc-dev-guide#1868)
- Improving macro expansion section (rust-lang/rustc-dev-guide#1875)
- Replace letters by foo, bar and buz in lexing example (rust-lang/rustc-dev-guide#1870)
- Fix some broken links (rust-lang/rustc-dev-guide#1877)
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Feb 13, 2024
Rollup merge of rust-lang#120979 - rustbot:docs-update, r=ehuss

Update books

## rust-lang/edition-guide

1 commits in baafacc6d8701269dab1e1e333f3547fb54b5a59..76bd48a273a0e0413a3bf22c699112d41497b99e
2024-02-10 20:50:34 UTC to 2024-02-10 20:50:34 UTC

- Set up scaffolding for 2024 (rust-lang/edition-guide#288)

## rust-lang/reference

4 commits in a0b119535e7740f68494c4f0582f7ad008b00ccd..8227666de13f6e7bb32dea9dc42e841adb5ce4b7
2024-02-12 03:04:15 UTC to 2024-01-30 20:10:53 UTC

- Fix a typo in external-blocks.md (rust-lang/reference#1467)
- Fix syntax in `'static lifetime elision` section of `lifetime-elision.md` (rust-lang/reference#1463)
- Fix markdown backslash for FLOAT_LITERAL (rust-lang/reference#1464)
- C string literal expressions (rust-lang/reference#1457)

## rust-lang/rust-by-example

5 commits in 179256a445d6144f5f371fdefb993f48f33978b0..e188d5d466f7f3ff9f1d518393235f4fe951be46
2024-02-07 17:16:00 UTC to 2024-01-31 17:34:10 UTC

- Update macros.md (rust-lang/rust-by-example#1815)
- Update borrow.md (rust-lang/rust-by-example#1814)
- Fixes the bug: rust-lang/rust-by-example#1721 (rust-lang/rust-by-example#1811)
- std_misc/process/pipe.md: Fix typo in pangram string (rust-lang/rust-by-example#1809)
- Add expected error behavior into docs (rust-lang/rust-by-example#1810)

## rust-lang/rustc-dev-guide

9 commits in ec287e332777627185be4798ad22599ffe7b84aa..1f30cc7cca9a3433bc1872abdc98960b36c21ca0
2024-02-11 05:36:15 UTC to 2024-01-29 19:49:51 UTC

- fix sentence (rust-lang/rustc-dev-guide#1882)
- Some updates for recent diagnostics changes. (rust-lang/rustc-dev-guide#1883)
- Rename occurrences of 'delay_span_bug' to 'span_delayed_bug' (rust-lang/rustc-dev-guide#1881)
- Update for upcoming markdown changes. (rust-lang/rustc-dev-guide#1880)
- Update uses of renamed BoxMeUp to PanicPayload (rust-lang/rustc-dev-guide#1878)
- Add links for arena and interning. (rust-lang/rustc-dev-guide#1868)
- Improving macro expansion section (rust-lang/rustc-dev-guide#1875)
- Replace letters by foo, bar and buz in lexing example (rust-lang/rustc-dev-guide#1870)
- Fix some broken links (rust-lang/rustc-dev-guide#1877)
github-actions bot pushed a commit to rust-lang/miri that referenced this pull request Feb 13, 2024
Update books

## rust-lang/edition-guide

1 commits in baafacc6d8701269dab1e1e333f3547fb54b5a59..76bd48a273a0e0413a3bf22c699112d41497b99e
2024-02-10 20:50:34 UTC to 2024-02-10 20:50:34 UTC

- Set up scaffolding for 2024 (rust-lang/edition-guide#288)

## rust-lang/reference

4 commits in a0b119535e7740f68494c4f0582f7ad008b00ccd..8227666de13f6e7bb32dea9dc42e841adb5ce4b7
2024-02-12 03:04:15 UTC to 2024-01-30 20:10:53 UTC

- Fix a typo in external-blocks.md (rust-lang/reference#1467)
- Fix syntax in `'static lifetime elision` section of `lifetime-elision.md` (rust-lang/reference#1463)
- Fix markdown backslash for FLOAT_LITERAL (rust-lang/reference#1464)
- C string literal expressions (rust-lang/reference#1457)

## rust-lang/rust-by-example

5 commits in 179256a445d6144f5f371fdefb993f48f33978b0..e188d5d466f7f3ff9f1d518393235f4fe951be46
2024-02-07 17:16:00 UTC to 2024-01-31 17:34:10 UTC

- Update macros.md (rust-lang/rust-by-example#1815)
- Update borrow.md (rust-lang/rust-by-example#1814)
- Fixes the bug: rust-lang/rust-by-example#1721 (rust-lang/rust-by-example#1811)
- std_misc/process/pipe.md: Fix typo in pangram string (rust-lang/rust-by-example#1809)
- Add expected error behavior into docs (rust-lang/rust-by-example#1810)

## rust-lang/rustc-dev-guide

9 commits in ec287e332777627185be4798ad22599ffe7b84aa..1f30cc7cca9a3433bc1872abdc98960b36c21ca0
2024-02-11 05:36:15 UTC to 2024-01-29 19:49:51 UTC

- fix sentence (rust-lang/rustc-dev-guide#1882)
- Some updates for recent diagnostics changes. (rust-lang/rustc-dev-guide#1883)
- Rename occurrences of 'delay_span_bug' to 'span_delayed_bug' (rust-lang/rustc-dev-guide#1881)
- Update for upcoming markdown changes. (rust-lang/rustc-dev-guide#1880)
- Update uses of renamed BoxMeUp to PanicPayload (rust-lang/rustc-dev-guide#1878)
- Add links for arena and interning. (rust-lang/rustc-dev-guide#1868)
- Improving macro expansion section (rust-lang/rustc-dev-guide#1875)
- Replace letters by foo, bar and buz in lexing example (rust-lang/rustc-dev-guide#1870)
- Fix some broken links (rust-lang/rustc-dev-guide#1877)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants