MCPcopy Create free account

hub / github.com/corrode/refactoring-rust / functions

Functions302 in github.com/corrode/refactoring-rust

Functionfinds_mode
()
examples/16_mode.rs:28
Functionfirst_few
()
solutions/03_even_numbers.rs:17
Functionfirst_few
()
examples/03_even_numbers.rs:24
Functionfirst_ten
()
solutions/19_iterators.rs:48
Functionfirst_ten
()
examples/19_iterators.rs:31
Functionflattens_ages
()
solutions/14_room_occupancy.rs:65
Functionflattens_ages
()
examples/14_room_occupancy.rs:79
Methodfmt
(&self, f: &mut fmt::Formatter<'_>)
solutions/27_mini_redis.rs:96
Methodfrom
(e: ParseIntError)
solutions/18_parse_srt_timestamp.rs:18
Functiongarbage_after_closing_quote_is_an_error
()
solutions/26_env_file_parser.rs:369
Functionget_debug
(config: &HashMap<String, String>)
examples/25_config_loader.rs:20
Functionget_host
(config: &HashMap<String, String>)
examples/25_config_loader.rs:13
Functionget_max_connections
(config: &HashMap<String, String>)
examples/25_config_loader.rs:27
Functionget_port
(config: &HashMap<String, String>)
examples/25_config_loader.rs:5
Functionhandle_response
(resp: Response)
solutions/24_http_response_router.rs:42
Functionhandle_response
(resp: Response)
examples/24_http_response_router.rs:14
Functionhash_inside_quotes_is_preserved
()
solutions/26_env_file_parser.rs:333
Functionhighest_and_lowest
Given a string of space-separated integers, return the highest and lowest value. Solution highlights: - `split_whitespace` handles tabs and runs of s
solutions/15_highest_and_lowest.rs:9
Functionhighest_and_lowest
Given a string of space-separated integers, return the highest and lowest value.
examples/15_highest_and_lowest.rs:4
Functionhset_returns_zero_on_field_update
()
solutions/27_mini_redis.rs:201
Functionhset_returns_zero_on_field_update
()
examples/27_mini_redis.rs:96
Functionhset_writes_to_hashes
()
solutions/27_mini_redis.rs:191
Functionhset_writes_to_hashes
()
examples/27_mini_redis.rs:86
Functioninline_comment_after_bare_value
()
solutions/26_env_file_parser.rs:363
Functioninvalid_value_silently_defaults
()
solutions/25_config_loader.rs:76
Functioninvalid_value_silently_defaults
()
examples/25_config_loader.rs:55
Functionis_excluded
(excluded: &Option<HashSet<PathBuf>>, path: &Path)
solutions/12_excluded_path.rs:12
Functionis_excluded
(excluded: &Option<HashSet<PathBuf>>, path: &Path)
examples/12_excluded_path.rs:7
Functionis_rust_source_file
(path: &Path)
solutions/05_path.rs:10
Functionis_rust_source_file
(path: &Path)
examples/05_path.rs:5
Functionis_valid_iban
Validate that a string looks like an IBAN. Solution highlights: - `match` with `|` arms maps country -> length declaratively. - `as_bytes()` indexing
solutions/23_iban_prefix_check.rs:9
Functionis_valid_iban
Validate that a string looks like an IBAN. Rules: - First two characters: ASCII letters (country code). - Next two characters: ASCII digits (check di
examples/23_iban_prefix_check.rs:9
Functionkeeps_line_without_tag
()
solutions/17_trim_log_line.rs:38
Functionkeeps_line_without_tag
()
examples/17_trim_log_line.rs:66
Functionline_number_tracks_across_lines
()
solutions/26_env_file_parser.rs:381
Functionlowercase_first
()
solutions/01_starts_with_uppercase.rs:27
Functionlowercase_first
()
examples/01_starts_with_uppercase.rs:25
Functionlpush_writes_to_lists_in_reverse_order
()
solutions/27_mini_redis.rs:179
Functionlpush_writes_to_lists_in_reverse_order
()
examples/27_mini_redis.rs:76
Functionmax_adults_in_a_room
(rooms: &[RoomOccupancy])
solutions/14_room_occupancy.rs:21
Functionmax_adults_in_a_room
(rooms: &[RoomOccupancy])
examples/14_room_occupancy.rs:26
Functionmax_port
()
solutions/10_parse_port.rs:31
Functionmax_port
()
examples/10_parse_port.rs:21
Functionmissing_equals_is_an_error
()
solutions/26_env_file_parser.rs:349
Functionmissing_file_is_error
()
solutions/09_error_handling.rs:36
Functionmissing_file_is_error
()
examples/09_error_handling.rs:38
Functionmost_common
(numbers: &[i32])
solutions/16_mode.rs:10
Functionmost_common
(numbers: &[i32])
examples/16_mode.rs:5
Functionnegatives
()
solutions/15_highest_and_lowest.rs:33
Functionnegatives
()
examples/15_highest_and_lowest.rs:38
Functionnested_rs_file
()
solutions/05_path.rs:29
Functionnested_rs_file
()
examples/05_path.rs:25
Methodnew
()
solutions/19_iterators.rs:16
Functionnext_advances_state
()
solutions/19_iterators.rs:54
Functionno_duplicates_unchanged
()
solutions/11_dedup_runs.rs:32
Functionno_duplicates_unchanged
()
examples/11_dedup_runs.rs:40
Functionno_extension
()
solutions/05_path.rs:39
Functionno_extension
()
examples/05_path.rs:35
Functionnon_digits_in_check
()
solutions/23_iban_prefix_check.rs:55
Functionnon_digits_in_check
()
examples/23_iban_prefix_check.rs:73
Functionnon_numeric_rejected
()
solutions/10_parse_port.rs:46
Functionnon_numeric_rejected
()
examples/10_parse_port.rs:36
Functionnone_means_nothing_excluded
()
solutions/12_excluded_path.rs:38
Functionnone_means_nothing_excluded
()
examples/12_excluded_path.rs:37
Functionnone_on_empty
()
solutions/06_nesting.rs:30
Functionnone_on_empty
()
examples/06_nesting.rs:32
Functionnone_on_none
()
solutions/06_nesting.rs:25
Functionnone_on_none
()
examples/06_nesting.rs:27
Functionnone_on_whitespace_only
()
solutions/06_nesting.rs:35
Functionnone_on_whitespace_only
()
examples/06_nesting.rs:37
Functionnot_found_fails
()
solutions/24_http_response_router.rs:91
Functionnot_found_fails
()
examples/24_http_response_router.rs:79
Functionnot_under_any_prefix
()
solutions/12_excluded_path.rs:33
Functionnot_under_any_prefix
()
examples/12_excluded_path.rs:32
Functionnothing_and_other
()
solutions/02_better_match.rs:36
Functionnothing_and_other
()
examples/02_better_match.rs:31
Functionodd_bound
()
solutions/03_even_numbers.rs:28
Functionodd_bound
()
examples/03_even_numbers.rs:34
Functionok_returns_body
()
solutions/24_http_response_router.rs:64
Functionok_returns_body
()
examples/24_http_response_router.rs:52
Functionone_invalid
()
solutions/08_parse_ints.rs:27
Functionone_invalid
()
examples/08_parse_ints.rs:28
Functionone_minute_twentythree_seconds
()
solutions/18_parse_srt_timestamp.rs:45
Functionone_minute_twentythree_seconds
()
examples/18_parse_srt_timestamp.rs:35
Functionother_extension
()
solutions/05_path.rs:34
Functionother_extension
()
examples/05_path.rs:30
Functionout_of_range_rejected
()
solutions/10_parse_port.rs:41
Functionout_of_range_rejected
()
examples/10_parse_port.rs:31
Functionparse_port
(s: &str)
solutions/10_parse_port.rs:16
Functionparse_port
Parse a TCP port string into a `u16`.
examples/10_parse_port.rs:3
Functionparse_srt_timestamp
(s: &str)
solutions/18_parse_srt_timestamp.rs:23
Functionparse_srt_timestamp
(s: &str)
examples/18_parse_srt_timestamp.rs:5
Functionparse_values
(values: &[String])
solutions/08_parse_ints.rs:12
Functionparse_values
(values: Vec<String>)
examples/08_parse_ints.rs:6
Functionplain_rs_file
()
solutions/05_path.rs:24
Functionplain_rs_file
()
examples/05_path.rs:20
Functionprimes
()
solutions/02_better_match.rs:22
Functionprimes
()
examples/02_better_match.rs:17
Functionquicksort
Sort a slice of integers with quicksort. Solution highlights: - A slice pattern (`[pivot, rest @ ..]`) splits head from tail and handles the empty ba
solutions/22_quicksort.rs:13
Functionquicksort
Sort a slice of integers with quicksort. This version works, but it's a mouthful: it copies into a `Vec`, then juggles indices through a hand-written
examples/22_quicksort.rs:9
← previousnext →101–200 of 302, ranked by callers