Files
rust/src
Nathan West 3ab7ae39ec Bring net/parser.rs up to modern up to date with modern rust patterns
Made the following changes throughout the IP address parser:
- Replaced all uses of `is_some()` / `is_none()` with `?`.
- "Upgraded" loops wherever possible; ie, replace `while` with `for`, etc.
    - Removed all cases of manual index tracking / incrementing.
- Renamed several single-character variables with more expressive names.
- Replaced several manual control flow segments with equivalent adapters (such as `Option::filter`).
- Removed `read_seq_3`; replaced with simple sequences of `?`.
- Parser now reslices its state when consuming, rather than carrying a separate state and index variable.
- `read_digit` now uses `char::to_digit`.
- Removed unnecessary casts back and forth between u8 and u32
- Added comments throughout, especially in the complex IPv6 parsing logic.
- Added comprehensive local unit tests for the parser to validate these changes.
2020-06-30 11:44:14 -07:00
..
2020-05-17 11:41:20 +02:00
2020-05-18 20:38:59 +02:00
2020-05-08 13:57:08 +02:00
2020-05-11 17:13:32 +02:00
2020-05-11 14:06:57 +08:00
2020-05-11 17:13:32 +02:00
2020-05-17 11:06:35 +02:00
2020-05-11 17:13:32 +02:00
2020-05-09 16:03:40 -04:00

This directory contains the source code of the rust project, including:

  • rustc and its tests
  • libstd
  • Various submodules for tools, like rustdoc, rls, etc.

For more information on how various parts of the compiler work, see the rustc dev guide.