Can't get .cpp out of simplemax

    Aug 12 2019 | 12:46 am
    I usually start by copying simplemax but renaming simplemax.c to simplemax.cpp causes a build fail.
    error: No matching function for call to 'object_alloc'
    xcode notes that 1. Candidate function not viable: cannot convert argument of incomplete type 'void *' to 't_class *' (aka 'maxclass *') for 1st argument
    What's the deal here

    • Aug 13 2019 | 12:51 pm
      C++ is fussier about types, and simplemax declares its class pointer as void*. If you change the declaration to static t_class *simplemax_class; You should be good.