:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
use hogvm::hog_stl;
pub fn main() {
// nosemgrep: rust.lang.security.args.args
let output_file = std::env::args()
.next_back()
.expect("Usage: stl_dump <output_file>");
println!("Writing to {output_file}");
let res = format!(
"RUST_HOGVM_STL = [\n {}\n]",
hogvm::stl()
.iter()
.map(|(name, _)| name.as_str())
.chain(hog_stl().functions().keys().map(|name| name.as_str()))
.map(|n| format!("\"{n}\""))
.collect::<Vec<_>>()
.join(",\n ")
);
std::fs::write(output_file, res.as_bytes()).expect("Failed to write output file");
}