Skip to content

Instantly share code, notes, and snippets.

@cppljevans
cppljevans / toy_why_define.cpp
Last active August 24, 2016 08:55
spirit toy.cpp modified to show need for BOOST_SPIRIT_DEFINE
//Purpose:
// Demonstrate the purpose BOOST_SPIRIT_DEFINE
// is to implement recursive rules.
//OriginalSource:
// https://github.com/boostorg/spirit/blob/develop/workbench/x3/toy/toy.cpp
//Modifications:
// Rm'ed use of context to implement recursiion and replaced with
// BOOST_SPIRIT_DEFINE
//===========================================================================
#include <iostream>