pub fn perp_underlying(symbol: &str) -> Option<&str>
Extract the underlying from a perp symbol (e.g., “BTC-PERP” -> “BTC”, “BTC” -> “BTC”). Returns None for option symbols or other hyphenated symbols that aren’t perps.
None