17#ifndef FRONTENDS_COMMON_CONSTANTPARSING_H_
18#define FRONTENDS_COMMON_CONSTANTPARSING_H_
20#include "lib/cstring.h"
72std::ostream &operator<<(std::ostream &out,
const UnparsedConstant &constant);
Definition source_file.h:125
TODO: this is not really specific to BMV2, it should reside somewhere else.
Definition applyOptionsPragmas.cpp:24
unsigned base
An ignored prefix of the numeric constant (e.g. '0x').
Definition constantParsing.h:68
IR::Constant * parseConstant(const Util::SourceInfo &srcInfo, const UnparsedConstant &constant, long defaultValue)
Definition constantParsing.cpp:63
unsigned skip
Raw P4 text which was recognized as a numeric constant.
Definition constantParsing.h:67
bool hasWidth
The base in which the constant is expressed.
Definition constantParsing.h:69
int parseConstantChecked(const Util::SourceInfo &srcInfo, const UnparsedConstant &constant)
Definition constantParsing.cpp:76
Definition constantParsing.h:65