Files
CWasm/cwasm.c

23 lines
526 B
C

/*
File: main.c
Author: Taylor Robbins
Date: 08\28\2025
Description:
** This file serves as the compilable file for all of CWasm. It may be #included by the app.c file
*/
#include "cwasm.h"
#include "std/src/std_main.c"
WASM_EXPORT(HelloFromWasm) float HelloFromWasm(float value, float value2)
{
printf("Called HelloFromWasm(%g)!\n", fmodf(value, value2));
for (int iIndex = 0; iIndex < 1024; iIndex++)
{
void* newMem = grow_mem(1024);
printf("mem[%d] = %p\n", iIndex, newMem);
}
return value*(value+1)*2;
}