MCPcopy Create free account
hub / github.com/Duet3D/RepRapFirmware / EvaluateConditionForDisplay

Method EvaluateConditionForDisplay

src/GCodes/GCodes.cpp:5859–5870  ·  view source on GitHub ↗

Evaluate a visibility expression string and return it

Source from the content-addressed store, hash-verified

5857
5858// Evaluate a visibility expression string and return it
5859bool GCodes::EvaluateConditionForDisplay(const char *_ecv_array str) const noexcept
5860{
5861 try
5862 {
5863 ExpressionParser parser(LcdGCode(), str, str + strlen(str));
5864 return parser.ParseBoolean();
5865 }
5866 catch (const GCodeException&)
5867 {
5868 return false;
5869 }
5870}
5871
5872// Evaluate a value string returning true if an error occurred
5873bool GCodes::EvaluateValueForDisplay(const char *_ecv_array str, ExpressionValue& expr) const noexcept

Callers 1

MenuItem.cppFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected