Currently, when a user provides a literal boolean option to leptos_fluent!, the library check if is a true or false literal boolean to include code or not. But the rustc compiler is enough smart to strip the conditional branching if true and if false, so we can use an expression for booleans, we don't need to parse them as possible literal booleans.
Currently, when a user provides a literal boolean option to
leptos_fluent!
, the library check if is atrue
orfalse
literal boolean to include code or not. But the rustc compiler is enough smart to strip the conditional branchingif true
andif false
, so we can use an expression for booleans, we don't need to parse them as possible literal booleans.This should make the macro faster.