#!/usr/bin/env node
// Enable Cheddar safe mode
global.SAFE_MODE = true;
var cheddar = require('cheddar-lang');
var api = cheddar.stdlib;
// Print function
var printed = false;
function print(text) {
printed = true;
process.stdout.write(text);
}
// Get the default return
var res = cheddar(process.argv[2], {
PRINT: print
});
// Check if function was returned
if (res instanceof api.func) {
var args = process.argv.slice(3).map(function(arg) {
// Convert it to a Cheddar string