PineForge unreleased
Deterministic PineScript v6 backtest runtime — C ABI reference
Loading...
Searching...
No Matches
log.hpp
Go to the documentation of this file.
1#pragma once
3#include <iostream>
4#include <string>
5#include <stdexcept>
6
7namespace pineforge {
8
9inline void pine_log_info(const std::string& msg) { std::cerr << "[INFO] " << msg << "\n"; }
10inline void pine_log_warning(const std::string& msg) { std::cerr << "[WARN] " << msg << "\n"; }
11inline void pine_log_error(const std::string& msg) { std::cerr << "[ERROR] " << msg << "\n"; }
12// runtime.error(): still a std::runtime_error whose what() is the message, now
13// coded strategy_runtime_error -- the only code a script's own text can read.
14[[noreturn]] inline void pine_runtime_error(const std::string& msg) {
16}
17
18} // namespace pineforge
Base with a code: throw coded<std::invalid_argument>(code, {args}, text).
void pine_log_warning(const std::string &msg)
Definition log.hpp:10
void pine_log_error(const std::string &msg)
Definition log.hpp:11
void pine_log_info(const std::string &msg)
Definition log.hpp:9
void pine_runtime_error(const std::string &msg)
Definition log.hpp:14