Skip to main content

is_lang

Function is_lang 

Source
pub fn is_lang(lang: Language, code: &str) -> bool
Expand description

Test for the given language, returns false if there is any syntax error, does not always return true otherwise (additional criteria may be used). Warnings may be emitted if the results are ambiguous. Works for any language, provided it is line-oriented.