Skip to main content

scan

Function scan 

Source
pub fn scan(source: &str, file: &str, patterns: &[Pattern]) -> Scan
Expand description

The keys a Rust source uses through patterns, with their English, and the constructor calls it could not read.

A callee is matched by its path’s last segments, however long the path and however it is laid out (helios::Message::new(, ::app::strings::Message::new(, a path or arguments split across lines, comments between). A call whose key is not a literal, or not a valid Fluent key, is skipped; when the pattern is a constructor (its callee ends in ::new, as StrKey::new), the call is also reported in Scan::unread with its file and line, and logged as a warning; so is a constructor whose English is not a literal (its key is still found, without English).